home *** CD-ROM | disk | FTP | other *** search
/ Gigarom 4 / Mac Giga-ROM 4.0 - 1993.toast / FILES / DEV / I-Z / ShellDA / ShellDA ƒ / DialogManagerDA.Pas < prev    next >
MacBinary  |  1986-11-27  |  15.0 KB  |  [TEXT/QED1]

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: MacBinary (archive/macBinary).

ConfidenceProgramDetectionMatch TypeSupport
10% dexvert MacBinary (archive/macBinary) fallback Supported
1% dexvert TheDraw Pascal screen Image (image/theDrawPascalScreenImage) ext Unsupported
1% dexvert Text File (text/txt) fallback Supported
100% file MacBinary II, Wed Nov 26 21:06:14 1986, modified Wed Nov 26 21:06:14 1986, creator 'QED1', type ASCII, 14644 bytes "DialogManagerDA.Pas" , at 0x39b4 406 bytes resource default (weak)
99% file data default
74% TrID Macintosh plain text (MacBinary) default
25% TrID MacBinary 2 default (weak)
100% siegfried fmt/1762 MacBinary (II) default
100% lsar MacBinary default


id metadata
keyvalue
macFileType[TEXT]
macFileCreator[QED1]



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 13 44 69 61 6c 6f 67 | 4d 61 6e 61 67 65 72 44 |..Dialog|ManagerD|
|00000010| 41 2e 50 61 73 00 00 00 | 00 00 00 00 00 00 00 00 |A.Pas...|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 51 45 44 | 31 00 00 00 00 00 00 00 |.TEXTQED|1.......|
|00000050| 00 00 00 00 00 39 34 00 | 00 01 96 9b f1 5b 16 9b |.....94.|.....[..|
|00000060| f1 5b 16 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |.[......|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 76 75 00 00 |........|....vu..|
|00000080| 50 52 4f 47 52 41 4d 20 | 20 20 44 69 61 6c 6f 67 |PROGRAM | Dialog|
|00000090| 4d 61 6e 61 67 65 72 44 | 41 3b 0d 0d 28 2a 20 44 |ManagerD|A;..(* D|
|000000a0| 65 73 6b 20 61 63 63 65 | 73 73 6f 72 79 20 74 6f |esk acce|ssory to|
|000000b0| 20 73 68 6f 77 20 74 68 | 65 20 73 74 72 75 63 74 | show th|e struct|
|000000c0| 75 72 65 20 6f 66 20 44 | 41 73 09 42 65 74 61 20 |ure of D|As.Beta |
|000000d0| 76 65 72 73 69 6f 6e 20 | 30 2e 39 20 5f 5f 20 31 |version |0.9 __ 1|
|000000e0| 31 2f 32 32 2f 38 36 0d | 09 62 79 20 57 69 6c 6c |1/22/86.|.by Will|
|000000f0| 69 61 6d 20 53 2e 20 4a | 6f 68 6e 73 6f 6e 2c 20 |iam S. J|ohnson, |
|00000100| 77 69 74 68 20 68 65 6c | 70 20 66 72 6f 6d 20 74 |with hel|p from t|
|00000110| 68 65 20 4d 41 43 69 6e | 63 69 6e 6e 61 74 69 20 |he MACin|cinnati |
|00000120| 48 61 63 6b 65 72 20 47 | 72 6f 75 70 2e 0d 09 57 |Hacker G|roup...W|
|00000130| 72 69 74 74 65 6e 20 69 | 6e 20 54 4d 4c 20 50 61 |ritten i|n TML Pa|
|00000140| 73 63 61 6c 2c 20 76 65 | 72 73 69 6f 6e 20 32 2e |scal, ve|rsion 2.|
|00000150| 30 0d 0d 54 68 69 73 20 | 64 65 73 6b 20 61 63 63 |0..This |desk acc|
|00000160| 65 73 73 6f 72 79 20 69 | 73 20 61 20 73 68 65 6c |essory i|s a shel|
|00000170| 6c 20 79 6f 75 20 63 61 | 6e 20 75 73 65 20 74 6f |l you ca|n use to|
|00000180| 20 75 6e 64 65 72 73 74 | 61 6e 64 20 74 68 65 20 | underst|and the |
|00000190| 73 74 72 75 63 74 75 72 | 65 20 6f 66 20 44 41 73 |structur|e of DAs|
|000001a0| 20 61 6e 64 20 68 6f 77 | 20 74 6f 20 75 73 65 20 | and how| to use |
|000001b0| 74 68 65 20 44 69 61 6c | 6f 67 0d 4d 61 6e 61 67 |the Dial|og.Manag|
|000001c0| 65 72 20 66 72 6f 6d 20 | 61 20 64 65 73 6b 20 61 |er from |a desk a|
|000001d0| 63 63 65 73 73 6f 72 79 | 2e 20 49 74 20 6d 61 6b |ccessory|. It mak|
|000001e0| 65 73 20 75 73 65 20 6f | 66 20 62 75 74 74 6f 6e |es use o|f button|
|000001f0| 73 2c 20 49 43 4f 4e 73 | 2c 20 72 61 64 69 6f 20 |s, ICONs|, radio |
|00000200| 62 75 74 74 6f 6e 73 2c | 20 74 65 78 74 20 62 6f |buttons,| text bo|
|00000210| 78 65 73 2c 20 61 6e 64 | 20 64 6f 65 73 0d 73 6f |xes, and| does.so|
|00000220| 6d 65 20 64 72 61 77 69 | 6e 67 20 6f 66 20 69 74 |me drawi|ng of it|
|00000230| 73 20 6f 77 6e 2e 20 49 | 74 73 20 6d 6f 73 74 20 |s own. I|ts most |
|00000240| 75 73 65 66 75 6c 20 66 | 65 61 74 75 72 65 20 77 |useful f|eature w|
|00000250| 69 6c 6c 20 61 64 6a 75 | 73 74 20 79 6f 75 72 20 |ill adju|st your |
|00000260| 4d 41 43 20 74 6f 20 44 | 61 79 6c 69 67 68 74 20 |MAC to D|aylight |
|00000270| 53 61 76 69 6e 67 73 20 | 54 69 6d 65 2e 2e 2e 2e |Savings |Time....|
|00000280| 2e 2e 2a 29 0d 0d 55 53 | 45 53 20 4d 61 63 49 6e |..*)..US|ES MacIn|
|00000290| 74 66 3b 0d 0d 43 4f 4e | 53 54 09 7b 64 69 61 6c |tf;..CON|ST.{dial|
|000002a0| 6f 67 20 69 74 65 6d 20 | 6c 69 73 74 7d 0d 09 09 |og item |list}...|
|000002b0| 44 65 66 42 75 74 74 6f | 6e 09 3d 20 31 3b 09 09 |DefButto|n.= 1;..|
|000002c0| 43 68 6b 5f 4f 6e 09 09 | 3d 20 31 3b 09 7b 63 68 |Chk_On..|= 1;.{ch|
|000002d0| 65 63 6b 20 6f 6e 2f 6f | 66 66 20 72 61 64 69 6f |eck on/o|ff radio|
|000002e0| 20 62 75 74 74 6f 6e 73 | 7d 0d 09 09 51 75 69 74 | buttons|}...Quit|
|000002f0| 42 75 74 74 6f 6e 09 3d | 20 32 3b 09 09 43 68 6b |Button.=| 2;..Chk|
|00000300| 5f 4f 66 66 09 09 3d 20 | 30 3b 0d 09 09 41 62 6f |_Off..= |0;...Abo|
|00000310| 75 74 42 75 74 74 6f 6e | 09 3d 20 33 3b 0d 09 09 |utButton|.= 3;...|
|00000320| 54 62 6f 78 09 09 3d 20 | 34 3b 09 09 43 4e 54 4c |Tbox..= |4;..CNTL|
|00000330| 5f 65 6e 61 62 6c 65 09 | 3d 20 30 3b 09 7b 65 6e |_enable.|= 0;.{en|
|00000340| 61 62 6c 65 20 63 6f 6e | 74 72 6f 6c 73 7d 0d 09 |able con|trols}..|
|00000350| 09 54 62 6f 78 49 49 09 | 09 3d 20 35 3b 09 09 43 |.TboxII.|.= 5;..C|
|00000360| 4e 54 4c 5f 64 69 73 61 | 62 6c 65 09 3d 20 32 35 |NTL_disa|ble.= 25|
|00000370| 35 3b 0d 09 09 52 61 64 | 69 6f 42 75 74 31 09 3d |5;...Rad|ioBut1.=|
|00000380| 20 36 3b 0d 09 09 52 61 | 64 69 6f 42 75 74 32 09 | 6;...Ra|dioBut2.|
|00000390| 3d 20 37 3b 09 09 4e 6f | 53 74 72 69 6e 67 73 09 |= 7;..No|Strings.|
|000003a0| 3d 20 33 3b 09 7b 20 23 | 20 6f 66 20 67 6c 6f 62 |= 3;.{ #| of glob|
|000003b0| 61 6c 20 73 74 72 69 6e | 67 73 20 7d 0d 09 09 52 |al strin|gs }...R|
|000003c0| 61 64 69 6f 42 75 74 33 | 09 3d 20 38 3b 0d 09 09 |adioBut3|.= 8;...|
|000003d0| 42 75 6c 6c 73 49 43 4f | 4e 09 3d 20 39 3b 0d 09 |BullsICO|N.= 9;..|
|000003e0| 09 54 45 6e 74 65 72 49 | 43 4f 4e 09 3d 20 31 30 |.TEnterI|CON.= 10|
|000003f0| 3b 0d 09 09 54 69 6d 65 | 42 75 74 74 6f 6e 09 3d |;...Time|Button.=|
|00000400| 20 31 31 3b 0d 09 09 52 | 65 73 65 74 42 75 74 74 | 11;...R|esetButt|
|00000410| 6f 6e 09 3d 20 31 32 3b | 0d 0d 54 59 50 45 0d 09 |on.= 12;|..TYPE..|
|00000420| 45 76 65 6e 74 50 6f 69 | 6e 74 65 72 20 3d 20 5e |EventPoi|nter = ^|
|00000430| 45 76 65 6e 74 52 65 63 | 6f 72 64 3b 0d 09 4c 70 |EventRec|ord;..Lp|
|00000440| 74 72 20 3d 20 5e 6c 6f | 6e 67 69 6e 74 3b 0d 09 |tr = ^lo|ngint;..|
|00000450| 73 74 72 32 35 20 3d 20 | 73 74 72 69 6e 67 5b 32 |str25 = |string[2|
|00000460| 35 5d 3b 09 09 09 7b 20 | 64 65 66 69 6e 65 20 61 |5];...{ |define a|
|00000470| 20 73 68 6f 72 74 20 73 | 74 72 69 6e 67 20 74 6f | short s|tring to|
|00000480| 20 63 6f 6e 73 75 6d 65 | 20 6c 65 73 73 20 67 6c | consume| less gl|
|00000490| 6f 62 61 6c 20 73 70 61 | 63 65 20 7d 0d 0d 09 44 |obal spa|ce }...D|
|000004a0| 41 47 6c 6f 62 61 6c 73 | 20 3d 20 72 65 63 6f 72 |AGlobals| = recor|
|000004b0| 64 09 09 09 7b 20 47 6c | 6f 62 61 6c 20 64 61 74 |d...{ Gl|obal dat|
|000004c0| 61 2e 20 53 74 6f 72 65 | 20 61 20 68 61 6e 64 6c |a. Store| a handl|
|000004d0| 65 20 74 6f 20 69 74 20 | 69 6e 20 44 65 76 69 63 |e to it |in Devic|
|000004e0| 65 2e 64 63 74 6c 53 74 | 6f 72 61 67 65 20 7d 0d |e.dctlSt|orage }.|
|000004f0| 09 09 46 69 6e 69 73 68 | 65 64 20 3a 09 62 6f 6f |..Finish|ed :.boo|
|00000500| 6c 65 61 6e 3b 0d 09 09 | 42 75 74 74 6f 6e 4e 6f |lean;...|ButtonNo|
|00000510| 20 3a 09 6c 6f 6e 67 69 | 6e 74 3b 0d 09 09 4e 75 | :.longi|nt;...Nu|
|00000520| 6d 62 65 72 3a 09 09 6c | 6f 6e 67 69 6e 74 3b 0d |mber:..l|ongint;.|
|00000530| 09 09 4e 6f 54 65 78 74 | 20 3a 09 09 6c 6f 6e 67 |..NoText| :..long|
|00000540| 69 6e 74 3b 0d 09 09 6d | 65 6e 75 48 61 6e 64 20 |int;...m|enuHand |
|00000550| 3a 09 6d 65 6e 75 48 61 | 6e 64 6c 65 3b 0d 09 09 |:.menuHa|ndle;...|
|00000560| 53 74 72 69 6e 67 41 72 | 72 61 79 20 3a 09 61 72 |StringAr|ray :.ar|
|00000570| 72 61 79 5b 31 2e 2e 4e | 6f 53 74 72 69 6e 67 73 |ray[1..N|oStrings|
|00000580| 5d 20 6f 66 20 73 74 72 | 32 35 3b 0d 09 65 6e 64 |] of str|25;..end|
|00000590| 3b 0d 0d 09 44 41 47 6c | 6f 62 61 6c 73 50 20 3d |;...DAGl|obalsP =|
|000005a0| 20 5e 44 41 47 6c 6f 62 | 61 6c 73 3b 09 09 7b 20 | ^DAGlob|als;..{ |
|000005b0| 64 65 66 69 6e 65 20 68 | 61 6e 64 6c 65 20 74 6f |define h|andle to|
|000005c0| 20 44 41 47 6c 6f 62 61 | 6c 73 20 72 65 63 6f 72 | DAGloba|ls recor|
|000005d0| 64 20 7d 0d 09 44 41 47 | 6c 6f 62 61 6c 73 48 20 |d }..DAG|lobalsH |
|000005e0| 3d 20 5e 44 41 47 6c 6f | 62 61 6c 73 50 3b 0d 0d |= ^DAGlo|balsP;..|
|000005f0| 09 44 65 76 69 63 65 43 | 6f 6e 74 72 6f 6c 52 65 |.DeviceC|ontrolRe|
|00000600| 63 20 3d 20 72 65 63 6f | 72 64 09 09 7b 72 65 70 |c = reco|rd..{rep|
|00000610| 6c 61 63 65 20 70 72 65 | 64 65 66 69 6e 65 64 20 |lace pre|defined |
|00000620| 44 43 74 6c 45 6e 74 72 | 79 20 72 65 63 6f 72 64 |DCtlEntr|y record|
|00000630| 20 69 6e 20 69 6e 74 65 | 72 66 61 63 65 20 66 69 | in inte|rface fi|
|00000640| 6c 65 73 20 7d 0d 09 09 | 64 43 74 6c 44 72 69 76 |les }...|dCtlDriv|
|00000650| 65 72 20 3a 09 48 61 6e | 64 6c 65 3b 0d 09 09 64 |er :.Han|dle;...d|
|00000660| 43 74 6c 46 6c 61 67 73 | 20 3a 09 49 6e 74 65 67 |CtlFlags| :.Integ|
|00000670| 65 72 3b 0d 09 09 64 43 | 74 6c 51 75 65 75 65 20 |er;...dC|tlQueue |
|00000680| 3a 09 49 6e 74 65 67 65 | 72 3b 0d 09 09 64 43 74 |:.Intege|r;...dCt|
|00000690| 6c 51 68 65 61 64 20 3a | 09 4c 70 74 72 3b 0d 09 |lQhead :|.Lptr;..|
|000006a0| 09 64 43 74 6c 51 74 61 | 69 6c 20 3a 09 4c 70 74 |.dCtlQta|il :.Lpt|
|000006b0| 72 3b 0d 09 09 64 43 74 | 6c 50 6f 73 69 74 69 6f |r;...dCt|lPositio|
|000006c0| 6e 20 3a 09 6c 6f 6e 67 | 69 6e 74 3b 0d 09 09 64 |n :.long|int;...d|
|000006d0| 43 74 6c 53 74 6f 72 61 | 67 65 20 3a 09 44 41 47 |CtlStora|ge :.DAG|
|000006e0| 6c 6f 62 61 6c 73 48 3b | 09 7b 64 65 66 69 6e 65 |lobalsH;|.{define|
|000006f0| 20 61 73 20 68 61 6e 64 | 6c 65 20 74 6f 20 67 6c | as hand|le to gl|
|00000700| 6f 62 61 6c 20 64 61 74 | 61 7d 0d 09 09 64 43 74 |obal dat|a}...dCt|
|00000710| 6c 52 65 66 4e 75 6d 20 | 3a 09 69 6e 74 65 67 65 |lRefNum |:.intege|
|00000720| 72 3b 0d 09 09 64 43 74 | 6c 43 75 72 54 69 63 6b |r;...dCt|lCurTick|
|00000730| 73 20 3a 09 6c 6f 6e 67 | 69 6e 74 3b 0d 09 09 64 |s :.long|int;...d|
|00000740| 43 74 6c 57 69 6e 64 6f | 77 20 3a 09 47 72 61 66 |CtlWindo|w :.Graf|
|00000750| 50 74 72 3b 0d 09 09 64 | 43 74 6c 44 65 6c 61 79 |Ptr;...d|CtlDelay|
|00000760| 20 3a 09 69 6e 74 65 67 | 65 72 3b 0d 09 09 64 43 | :.integ|er;...dC|
|00000770| 74 6c 45 6d 61 73 6b 20 | 3a 09 69 6e 74 65 67 65 |tlEmask |:.intege|
|00000780| 72 3b 0d 09 09 64 43 74 | 6c 4d 65 6e 75 20 3a 09 |r;...dCt|lMenu :.|
|00000790| 69 6e 74 65 67 65 72 3b | 0d 09 65 6e 64 3b 0d 0d |integer;|..end;..|
|000007a0| 50 52 4f 43 45 44 55 52 | 45 20 49 74 65 6d 41 63 |PROCEDUR|E ItemAc|
|000007b0| 74 69 76 61 74 65 20 28 | 74 68 65 44 69 61 6c 6f |tivate (|theDialo|
|000007c0| 67 20 3a 20 44 69 61 6c | 6f 67 50 74 72 3b 49 74 |g : Dial|ogPtr;It|
|000007d0| 65 6d 4e 6f 2c 20 48 69 | 6c 69 74 65 4d 6f 64 65 |emNo, Hi|liteMode|
|000007e0| 20 3a 20 69 6e 74 65 67 | 65 72 29 3b 09 7b 20 41 | : integ|er);.{ A|
|000007f0| 63 74 69 76 61 74 65 20 | 26 20 68 69 6c 69 74 65 |ctivate |& hilite|
|00000800| 20 62 75 74 74 6f 6e 73 | 20 7d 0d 56 61 72 0d 09 | buttons| }.Var..|
|00000810| 49 74 65 6d 54 79 70 65 | 3a 20 49 6e 74 65 67 65 |ItemType|: Intege|
|00000820| 72 3b 0d 09 49 74 65 6d | 42 6f 78 3a 20 20 52 65 |r;..Item|Box: Re|
|00000830| 63 74 3b 0d 09 49 74 65 | 6d 48 64 6c 20 3a 20 20 |ct;..Ite|mHdl : |
|00000840| 48 61 6e 64 6c 65 3b 0d | 42 65 67 69 6e 0d 09 47 |Handle;.|Begin..G|
|00000850| 65 74 44 49 74 65 6d 28 | 74 68 65 44 69 61 6c 6f |etDItem(|theDialo|
|00000860| 67 2c 49 74 65 6d 4e 6f | 2c 49 74 65 6d 54 79 70 |g,ItemNo|,ItemTyp|
|00000870| 65 2c 49 74 65 6d 48 64 | 6c 2c 49 74 65 6d 42 6f |e,ItemHd|l,ItemBo|
|00000880| 78 29 3b 0d 09 48 69 6c | 69 74 65 43 6f 6e 74 72 |x);..Hil|iteContr|
|00000890| 6f 6c 28 43 6f 6e 74 72 | 6f 6c 48 61 6e 64 6c 65 |ol(Contr|olHandle|
|000008a0| 28 49 74 65 6d 48 64 6c | 29 2c 48 69 6c 69 74 65 |(ItemHdl|),Hilite|
|000008b0| 4d 6f 64 65 29 3b 0d 45 | 6e 64 3b 0d 0d 50 52 4f |Mode);.E|nd;..PRO|
|000008c0| 43 45 44 55 52 45 20 53 | 65 74 52 61 64 69 6f 42 |CEDURE S|etRadioB|
|000008d0| 75 74 74 6f 6e 20 28 74 | 68 65 44 69 61 6c 6f 67 |utton (t|heDialog|
|000008e0| 20 3a 20 44 69 61 6c 6f | 67 50 74 72 3b 20 49 74 | : Dialo|gPtr; It|
|000008f0| 65 6d 4e 6f 2c 20 43 68 | 6b 4d 61 72 6b 20 3a 20 |emNo, Ch|kMark : |
|00000900| 69 6e 74 65 67 65 72 29 | 3b 20 7b 20 73 65 74 20 |integer)|; { set |
|00000910| 6f 6e 2f 6f 66 66 20 72 | 61 64 69 6f 20 62 75 74 |on/off r|adio but|
|00000920| 74 6f 6e 73 20 7d 0d 56 | 61 72 0d 09 49 74 65 6d |tons }.V|ar..Item|
|00000930| 54 79 70 65 3a 20 49 6e | 74 65 67 65 72 3b 0d 09 |Type: In|teger;..|
|00000940| 49 74 65 6d 42 6f 78 3a | 20 20 52 65 63 74 3b 0d |ItemBox:| Rect;.|
|00000950| 09 49 74 65 6d 48 64 6c | 3a 20 20 48 61 6e 64 6c |.ItemHdl|: Handl|
|00000960| 65 3b 0d 42 65 67 69 6e | 0d 09 47 65 74 44 49 74 |e;.Begin|..GetDIt|
|00000970| 65 6d 28 74 68 65 44 69 | 61 6c 6f 67 2c 49 74 65 |em(theDi|alog,Ite|
|00000980| 6d 4e 6f 2c 49 74 65 6d | 54 79 70 65 2c 49 74 65 |mNo,Item|Type,Ite|
|00000990| 6d 48 64 6c 2c 49 74 65 | 6d 42 6f 78 29 3b 0d 09 |mHdl,Ite|mBox);..|
|000009a0| 53 65 74 43 74 6c 56 61 | 6c 75 65 28 43 6f 6e 74 |SetCtlVa|lue(Cont|
|000009b0| 72 6f 6c 48 61 6e 64 6c | 65 28 49 74 65 6d 48 64 |rolHandl|e(ItemHd|
|000009c0| 6c 29 2c 20 43 68 6b 4d | 61 72 6b 29 3b 0d 45 6e |l), ChkM|ark);.En|
|000009d0| 64 3b 0d 0d 46 55 4e 43 | 54 49 4f 4e 20 47 65 74 |d;..FUNC|TION Get|
|000009e0| 54 78 74 56 61 6c 75 65 | 20 28 74 68 65 44 69 61 |TxtValue| (theDia|
|000009f0| 6c 6f 67 20 3a 20 44 69 | 61 6c 6f 67 50 74 72 3b |log : Di|alogPtr;|
|00000a00| 20 49 74 65 6d 4e 6f 20 | 3a 20 49 6e 74 65 67 65 | ItemNo |: Intege|
|00000a10| 72 29 3a 20 6c 6f 6e 67 | 69 6e 74 3b 09 7b 20 67 |r): long|int;.{ g|
|00000a20| 65 74 20 69 6e 74 65 67 | 65 72 20 66 72 6f 6d 20 |et integ|er from |
|00000a30| 74 65 78 74 20 62 6f 78 | 20 7d 0d 56 61 72 0d 09 |text box| }.Var..|
|00000a40| 49 74 65 6d 54 79 70 65 | 09 3a 20 49 6e 74 65 67 |ItemType|.: Integ|
|00000a50| 65 72 3b 0d 09 49 74 65 | 6d 42 6f 78 09 3a 20 52 |er;..Ite|mBox.: R|
|00000a60| 65 63 74 3b 0d 09 49 74 | 65 6d 48 64 6c 09 3a 20 |ect;..It|emHdl.: |
|00000a70| 48 61 6e 64 6c 65 3b 0d | 09 74 68 65 53 74 72 69 |Handle;.|.theStri|
|00000a80| 6e 67 09 3a 20 53 74 72 | 32 35 35 3b 0d 09 56 61 |ng.: Str|255;..Va|
|00000a90| 6c 75 65 09 3a 20 6c 6f | 6e 67 69 6e 74 3b 0d 62 |lue.: lo|ngint;.b|
|00000aa0| 65 67 69 6e 0d 09 47 65 | 74 44 49 74 65 6d 28 74 |egin..Ge|tDItem(t|
|00000ab0| 68 65 44 69 61 6c 6f 67 | 2c 20 49 74 65 6d 4e 6f |heDialog|, ItemNo|
|00000ac0| 2c 20 49 74 65 6d 54 79 | 70 65 2c 20 49 74 65 6d |, ItemTy|pe, Item|
|00000ad0| 48 64 6c 2c 20 49 74 65 | 6d 42 6f 78 29 3b 0d 09 |Hdl, Ite|mBox);..|
|00000ae0| 47 65 74 49 54 65 78 74 | 28 49 74 65 6d 48 64 6c |GetIText|(ItemHdl|
|00000af0| 2c 20 74 68 65 53 74 72 | 69 6e 67 29 3b 0d 09 53 |, theStr|ing);..S|
|00000b00| 74 72 69 6e 67 54 6f 4e | 75 6d 20 28 74 68 65 53 |tringToN|um (theS|
|00000b10| 74 72 69 6e 67 2c 20 56 | 61 6c 75 65 29 3b 0d 09 |tring, V|alue);..|
|00000b20| 47 65 74 54 78 74 56 61 | 6c 75 65 20 3a 3d 20 56 |GetTxtVa|lue := V|
|00000b30| 61 6c 75 65 3b 0d 65 6e | 64 3b 0d 0d 50 52 4f 43 |alue;.en|d;..PROC|
|00000b40| 45 44 55 52 45 20 48 69 | 6c 69 74 65 44 65 66 42 |EDURE Hi|liteDefB|
|00000b50| 75 74 74 6f 6e 20 28 74 | 68 65 44 69 61 6c 6f 67 |utton (t|heDialog|
|00000b60| 3a 20 44 69 61 6c 6f 67 | 50 74 72 29 3b 0d 76 61 |: Dialog|Ptr);.va|
|00000b70| 72 0d 09 49 74 65 6d 54 | 79 70 65 3a 09 49 6e 74 |r..ItemT|ype:.Int|
|00000b80| 65 67 65 72 3b 0d 09 42 | 75 74 74 52 65 63 74 3a |eger;..B|uttRect:|
|00000b90| 09 72 65 63 74 3b 0d 09 | 49 74 65 6d 48 64 6c 20 |.rect;..|ItemHdl |
|00000ba0| 3a 09 09 48 61 6e 64 6c | 65 3b 0d 62 65 67 69 6e |:..Handl|e;.begin|
|00000bb0| 0d 09 50 65 6e 53 69 7a | 65 28 33 2c 33 29 3b 09 |..PenSiz|e(3,3);.|
|00000bc0| 09 09 09 09 09 09 09 7b | 73 65 74 20 70 65 6e 20 |.......{|set pen |
|00000bd0| 73 69 7a 65 7d 0d 09 47 | 65 74 44 49 74 65 6d 28 |size}..G|etDItem(|
|00000be0| 74 68 65 44 69 61 6c 6f | 67 2c 31 2c 49 74 65 6d |theDialo|g,1,Item|
|00000bf0| 54 79 70 65 2c 49 74 65 | 6d 48 64 6c 2c 42 75 74 |Type,Ite|mHdl,But|
|00000c00| 74 52 65 63 74 29 3b 0d | 09 49 6e 73 65 74 52 65 |tRect);.|.InsetRe|
|00000c10| 63 74 28 42 75 74 74 52 | 65 63 74 2c 2d 34 2c 2d |ct(ButtR|ect,-4,-|
|00000c20| 34 29 3b 0d 09 46 72 61 | 6d 65 52 6f 75 6e 64 52 |4);..Fra|meRoundR|
|00000c30| 65 63 74 28 42 75 74 74 | 52 65 63 74 2c 32 38 2c |ect(Butt|Rect,28,|
|00000c40| 32 38 29 3b 0d 09 50 65 | 6e 53 69 7a 65 28 31 2c |28);..Pe|nSize(1,|
|00000c50| 31 29 3b 09 09 09 09 09 | 09 09 09 7b 72 65 73 65 |1);.....|...{rese|
|00000c60| 74 20 70 65 6e 20 73 69 | 7a 65 7d 0d 65 6e 64 3b |t pen si|ze}.end;|
|00000c70| 0d 0d 50 52 4f 43 45 44 | 55 52 45 20 44 72 61 77 |..PROCED|URE Draw|
|00000c80| 45 54 65 78 74 20 28 56 | 41 52 20 44 61 74 61 52 |EText (V|AR DataR|
|00000c90| 65 63 3a 20 44 41 47 6c | 6f 62 61 6c 73 29 3b 09 |ec: DAGl|obals);.|
|00000ca0| 09 7b 20 70 75 74 20 74 | 65 78 74 20 66 72 6f 6d |.{ put t|ext from|
|00000cb0| 20 47 6c 6f 62 61 6c 73 | 20 69 6e 20 64 69 61 6c | Globals| in dial|
|00000cc0| 6f 67 20 7d 0d 56 61 72 | 0d 09 56 4c 6f 63 2c 20 |og }.Var|..VLoc, |
|00000cd0| 63 6f 75 6e 74 65 72 3a | 09 69 6e 74 65 67 65 72 |counter:|.integer|
|00000ce0| 3b 0d 42 65 67 69 6e 0d | 09 77 69 74 68 20 44 61 |;.Begin.|.with Da|
|00000cf0| 74 61 52 65 63 20 64 6f | 20 62 65 67 69 6e 0d 09 |taRec do| begin..|
|00000d00| 09 54 65 78 74 46 6f 6e | 74 28 33 29 3b 09 7b 20 |.TextFon|t(3);.{ |
|00000d10| 6d 61 6b 65 20 47 65 6e | 65 76 61 20 39 20 70 74 |make Gen|eva 9 pt|
|00000d20| 2e 20 74 68 65 20 63 75 | 72 72 65 6e 74 20 66 6f |. the cu|rrent fo|
|00000d30| 6e 74 20 7d 0d 09 09 54 | 65 78 74 53 69 7a 65 28 |nt }...T|extSize(|
|00000d40| 39 29 3b 0d 09 09 66 6f | 72 20 63 6f 75 6e 74 65 |9);...fo|r counte|
|00000d50| 72 20 3a 3d 20 31 20 74 | 6f 20 4e 6f 54 65 78 74 |r := 1 t|o NoText|
|00000d60| 20 64 6f 20 62 65 67 69 | 6e 0d 09 09 09 56 4c 6f | do begi|n....VLo|
|00000d70| 63 20 3a 3d 20 38 30 20 | 2b 20 28 63 6f 75 6e 74 |c := 80 |+ (count|
|00000d80| 65 72 2a 31 34 29 3b 0d | 09 09 09 4d 6f 76 65 54 |er*14);.|...MoveT|
|00000d90| 6f 28 31 32 2c 56 4c 6f | 63 29 3b 0d 09 09 09 44 |o(12,VLo|c);....D|
|00000da0| 72 61 77 53 74 72 69 6e | 67 20 28 20 53 74 72 69 |rawStrin|g ( Stri|
|00000db0| 6e 67 41 72 72 61 79 5b | 63 6f 75 6e 74 65 72 5d |ngArray[|counter]|
|00000dc0| 20 29 3b 0d 09 09 65 6e | 64 3b 09 7b 77 69 74 68 | );...en|d;.{with|
|00000dd0| 20 44 61 74 61 52 65 63 | 20 64 6f 20 2d 20 66 6f | DataRec| do - fo|
|00000de0| 72 20 63 6f 75 6e 74 65 | 72 7d 0d 09 09 54 65 78 |r counte|r}...Tex|
|00000df0| 74 46 6f 6e 74 28 30 29 | 3b 09 7b 20 6d 61 6b 65 |tFont(0)|;.{ make|
|00000e00| 20 43 68 69 63 61 67 6f | 20 31 32 20 70 74 2e 20 | Chicago| 12 pt. |
|00000e10| 74 68 65 20 63 75 72 72 | 65 6e 74 20 66 6f 6e 74 |the curr|ent font|
|00000e20| 20 7d 0d 09 09 54 65 78 | 74 53 69 7a 65 28 31 32 | }...Tex|tSize(12|
|00000e30| 29 3b 0d 09 65 6e 64 3b | 0d 45 6e 64 3b 0d 0d 50 |);..end;|.End;..P|
|00000e40| 52 4f 43 45 44 55 52 45 | 20 44 69 74 6c 54 65 78 |ROCEDURE| DitlTex|
|00000e50| 74 28 56 41 52 20 44 61 | 74 61 52 65 63 3a 20 44 |t(VAR Da|taRec: D|
|00000e60| 41 47 6c 6f 62 61 6c 73 | 29 3b 09 7b 20 44 72 61 |AGlobals|);.{ Dra|
|00000e70| 77 20 74 65 78 74 20 61 | 6e 64 20 6f 75 74 70 75 |w text a|nd outpu|
|00000e80| 74 20 64 61 74 61 20 69 | 6e 20 6d 61 69 6e 20 77 |t data i|n main w|
|00000e90| 69 6e 64 6f 77 20 7d 0d | 76 61 72 0d 09 61 53 74 |indow }.|var..aSt|
|00000ea0| 72 69 6e 67 09 3a 20 73 | 74 72 32 35 35 3b 0d 62 |ring.: s|tr255;.b|
|00000eb0| 65 67 69 6e 0d 09 77 69 | 74 68 20 44 61 74 61 52 |egin..wi|th DataR|
|00000ec0| 65 63 20 64 6f 20 62 65 | 67 69 6e 0d 09 09 69 66 |ec do be|gin...if|
|00000ed0| 20 28 4e 6f 54 65 78 74 | 20 3e 20 30 29 20 74 68 | (NoText| > 0) th|
|00000ee0| 65 6e 20 44 72 61 77 45 | 54 65 78 74 20 28 44 61 |en DrawE|Text (Da|
|00000ef0| 74 61 52 65 63 29 3b 0d | 09 09 69 66 20 28 4e 75 |taRec);.|..if (Nu|
|00000f00| 6d 62 65 72 3e 30 29 20 | 74 68 65 6e 20 62 65 67 |mber>0) |then beg|
|00000f10| 69 6e 09 09 7b 20 64 72 | 61 77 20 72 65 73 75 6c |in..{ dr|aw resul|
|00000f20| 74 20 6f 66 20 6d 75 6c | 74 69 70 6c 69 63 61 74 |t of mul|tiplicat|
|00000f30| 69 6f 6e 20 7d 0d 09 09 | 09 4d 6f 76 65 54 6f 28 |ion }...|.MoveTo(|
|00000f40| 33 30 30 2c 37 36 29 3b | 0d 09 09 09 4e 75 6d 54 |300,76);|....NumT|
|00000f50| 6f 53 74 72 69 6e 67 20 | 28 4e 75 6d 62 65 72 2c |oString |(Number,|
|00000f60| 20 61 53 74 72 69 6e 67 | 29 3b 0d 09 09 09 44 72 | aString|);....Dr|
|00000f70| 61 77 53 74 72 69 6e 67 | 20 28 61 53 74 72 69 6e |awString| (aStrin|
|00000f80| 67 29 3b 0d 09 09 65 6e | 64 3b 0d 09 65 6e 64 3b |g);...en|d;..end;|
|00000f90| 0d 65 6e 64 3b 0d 0d 50 | 52 4f 43 45 44 55 52 45 |.end;..P|ROCEDURE|
|00000fa0| 20 44 69 74 6c 4c 69 6e | 65 73 3b 09 09 7b 20 64 | DitlLin|es;..{ d|
|00000fb0| 72 61 77 20 64 6f 74 74 | 65 64 20 6c 69 6e 65 73 |raw dott|ed lines|
|00000fc0| 20 69 6e 20 6d 61 69 6e | 20 77 69 6e 64 6f 77 20 | in main| window |
|00000fd0| 7d 0d 76 61 72 0d 09 50 | 61 74 74 72 6e 20 3a 09 |}.var..P|attrn :.|
|00000fe0| 09 50 61 74 74 65 72 6e | 3b 0d 62 65 67 69 6e 0d |.Pattern|;.begin.|
|00000ff0| 09 47 65 74 49 6e 64 50 | 61 74 74 65 72 6e 28 50 |.GetIndP|attern(P|
|00001000| 61 74 74 72 6e 2c 30 2c | 34 29 3b 09 7b 73 65 74 |attrn,0,|4);.{set|
|00001010| 20 70 65 6e 20 70 61 74 | 74 65 72 6e 20 74 6f 20 | pen pat|tern to |
|00001020| 67 72 61 79 7d 0d 09 50 | 65 6e 50 61 74 28 50 61 |gray}..P|enPat(Pa|
|00001030| 74 74 72 6e 29 3b 0d 09 | 4d 6f 76 65 54 6f 28 31 |ttrn);..|MoveTo(1|
|00001040| 38 32 2c 34 30 29 3b 09 | 09 09 7b 20 76 65 72 74 |82,40);.|..{ vert|
|00001050| 69 63 61 6c 20 6c 69 6e | 65 20 7d 0d 09 4c 69 6e |ical lin|e }..Lin|
|00001060| 65 28 30 2c 31 39 34 29 | 3b 0d 09 4d 6f 76 65 54 |e(0,194)|;..MoveT|
|00001070| 6f 28 33 30 30 2c 38 30 | 29 3b 09 09 09 7b 20 68 |o(300,80|);...{ h|
|00001080| 6f 72 69 7a 6f 6e 74 61 | 6c 20 6c 69 6e 65 20 7d |orizonta|l line }|
|00001090| 0d 09 4c 69 6e 65 28 35 | 30 2c 30 29 3b 0d 09 47 |..Line(5|0,0);..G|
|000010a0| 65 74 49 6e 64 50 61 74 | 74 65 72 6e 28 50 61 74 |etIndPat|tern(Pat|
|000010b0| 74 72 6e 2c 30 2c 31 29 | 3b 09 7b 72 65 73 65 74 |trn,0,1)|;.{reset|
|000010c0| 20 70 65 6e 20 70 61 74 | 74 65 72 6e 20 74 6f 20 | pen pat|tern to |
|000010d0| 62 6c 61 63 6b 7d 0d 09 | 50 65 6e 50 61 74 28 50 |black}..|PenPat(P|
|000010e0| 61 74 74 72 6e 29 3b 0d | 65 6e 64 3b 0d 0d 50 52 |attrn);.|end;..PR|
|000010f0| 4f 43 45 44 55 52 45 20 | 49 6e 69 74 44 6c 6f 67 |OCEDURE |InitDlog|
|00001100| 53 74 61 74 75 73 28 56 | 41 52 20 64 65 76 69 63 |Status(V|AR devic|
|00001110| 65 3a 20 44 65 76 69 63 | 65 43 6f 6e 74 72 6f 6c |e: Devic|eControl|
|00001120| 52 65 63 29 3b 09 7b 20 | 73 65 74 20 62 75 74 74 |Rec);.{ |set butt|
|00001130| 6f 6e 73 2c 20 67 6c 6f | 62 61 6c 73 2c 20 61 6e |ons, glo|bals, an|
|00001140| 64 20 63 75 72 73 6f 72 | 20 6c 6f 63 61 74 69 6f |d cursor| locatio|
|00001150| 6e 20 7d 0d 42 65 67 69 | 6e 0d 09 77 69 74 68 20 |n }.Begi|n..with |
|00001160| 64 65 76 69 63 65 20 64 | 6f 20 62 65 67 69 6e 0d |device d|o begin.|
|00001170| 09 09 53 65 74 52 61 64 | 69 6f 42 75 74 74 6f 6e |..SetRad|ioButton|
|00001180| 28 44 63 74 6c 57 69 6e | 64 6f 77 2c 20 52 61 64 |(DctlWin|dow, Rad|
|00001190| 69 6f 42 75 74 31 2c 20 | 43 68 6b 5f 4f 6e 29 3b |ioBut1, |Chk_On);|
|000011a0| 0d 09 09 53 65 74 52 61 | 64 69 6f 42 75 74 74 6f |...SetRa|dioButto|
|000011b0| 6e 28 44 63 74 6c 57 69 | 6e 64 6f 77 2c 20 52 61 |n(DctlWi|ndow, Ra|
|000011c0| 64 69 6f 42 75 74 32 2c | 20 63 68 6b 5f 6f 66 66 |dioBut2,| chk_off|
|000011d0| 29 3b 0d 09 09 53 65 74 | 52 61 64 69 6f 42 75 74 |);...Set|RadioBut|
|000011e0| 74 6f 6e 28 44 63 74 6c | 57 69 6e 64 6f 77 2c 20 |ton(Dctl|Window, |
|000011f0| 52 61 64 69 6f 42 75 74 | 33 2c 20 63 68 6b 5f 6f |RadioBut|3, chk_o|
|00001200| 66 66 29 3b 0d 09 09 49 | 74 65 6d 41 63 74 69 76 |ff);...I|temActiv|
|00001210| 61 74 65 20 28 44 43 74 | 6c 57 69 6e 64 6f 77 2c |ate (DCt|lWindow,|
|00001220| 20 52 65 73 65 74 42 75 | 74 74 6f 6e 2c 20 43 4e | ResetBu|tton, CN|
|00001230| 54 4c 5f 64 69 73 61 62 | 6c 65 29 3b 0d 09 09 64 |TL_disab|le);...d|
|00001240| 43 74 6c 53 74 6f 72 61 | 67 65 5e 5e 2e 42 75 74 |CtlStora|ge^^.But|
|00001250| 74 6f 6e 4e 6f 20 3a 3d | 20 31 3b 0d 09 09 64 43 |tonNo :=| 1;...dC|
|00001260| 74 6c 53 74 6f 72 61 67 | 65 5e 5e 2e 4e 6f 54 65 |tlStorag|e^^.NoTe|
|00001270| 78 74 20 3a 3d 20 30 3b | 0d 09 09 64 43 74 6c 53 |xt := 0;|...dCtlS|
|00001280| 74 6f 72 61 67 65 5e 5e | 2e 4e 75 6d 62 65 72 20 |torage^^|.Number |
|00001290| 3a 3d 20 30 3b 0d 09 09 | 53 65 6c 49 54 65 78 74 |:= 0;...|SelIText|
|000012a0| 20 28 44 43 74 6c 57 69 | 6e 64 6f 77 2c 20 54 62 | (DCtlWi|ndow, Tb|
|000012b0| 6f 78 2c 20 30 2c 20 30 | 29 3b 09 09 7b 6a 75 6d |ox, 0, 0|);..{jum|
|000012c0| 70 73 74 61 72 74 20 63 | 75 72 73 6f 72 20 69 6e |pstart c|ursor in|
|000012d0| 20 31 73 74 20 74 65 78 | 74 62 6f 78 7d 0d 09 65 | 1st tex|tbox}..e|
|000012e0| 6e 64 3b 0d 45 6e 64 3b | 0d 0d 50 52 4f 43 45 44 |nd;.End;|..PROCED|
|000012f0| 55 52 45 20 44 6f 41 62 | 6f 75 74 20 28 44 6c 6f |URE DoAb|out (Dlo|
|00001300| 67 49 44 09 3a 20 6c 6f | 6e 67 69 6e 74 29 3b 0d |gID.: lo|ngint);.|
|00001310| 56 61 72 0d 09 69 74 65 | 6d 09 09 3a 20 69 6e 74 |Var..ite|m..: int|
|00001320| 65 67 65 72 3b 0d 09 56 | 69 65 77 52 65 63 74 09 |eger;..V|iewRect.|
|00001330| 09 3a 20 72 65 63 74 3b | 09 7b 73 69 7a 65 20 6f |.: rect;|.{size o|
|00001340| 66 20 64 69 61 6c 6f 67 | 20 77 69 6e 64 6f 77 7d |f dialog| window}|
|00001350| 0d 09 44 49 54 4c 5f 48 | 64 6c 09 09 3a 20 68 61 |..DITL_H|dl..: ha|
|00001360| 6e 64 6c 65 3b 0d 09 41 | 62 6f 75 74 44 70 74 72 |ndle;..A|boutDptr|
|00001370| 09 3a 20 47 72 61 66 50 | 74 72 3b 0d 42 65 67 69 |.: GrafP|tr;.Begi|
|00001380| 6e 0d 09 53 65 74 52 65 | 63 74 28 56 69 65 77 52 |n..SetRe|ct(ViewR|
|00001390| 65 63 74 2c 36 38 2c 35 | 30 2c 34 34 34 2c 32 32 |ect,68,5|0,444,22|
|000013a0| 30 29 3b 09 7b 64 69 61 | 6c 6f 67 20 62 6f 78 20 |0);.{dia|log box |
|000013b0| 73 69 7a 65 2d 20 6c 66 | 2c 74 70 2c 72 74 2c 62 |size- lf|,tp,rt,b|
|000013c0| 6f 74 7d 0d 09 44 49 54 | 4c 5f 48 64 6c 20 3a 3d |ot}..DIT|L_Hdl :=|
|000013d0| 20 47 65 74 52 65 73 6f | 75 72 63 65 28 27 44 49 | GetReso|urce('DI|
|000013e0| 54 4c 27 2c 20 44 6c 6f | 67 49 44 29 3b 0d 09 69 |TL', Dlo|gID);..i|
|000013f0| 66 20 44 49 54 4c 5f 48 | 64 6c 20 3c 3e 20 6e 69 |f DITL_H|dl <> ni|
|00001400| 6c 20 74 68 65 6e 20 62 | 65 67 69 6e 09 09 09 0d |l then b|egin....|
|00001410| 09 09 41 62 6f 75 74 44 | 70 74 72 3a 3d 20 4e 65 |..AboutD|ptr:= Ne|
|00001420| 77 44 69 61 6c 6f 67 28 | 4e 69 6c 2c 09 09 7b 55 |wDialog(|Nil,..{U|
|00001430| 73 65 20 5f 4e 65 77 44 | 69 61 6c 6f 67 5f 20 74 |se _NewD|ialog_ t|
|00001440| 6f 20 70 75 74 20 75 70 | 20 6f 6e 65 20 6f 66 20 |o put up| one of |
|00001450| 32 20 64 69 66 66 65 72 | 65 6e 74 20 44 49 54 4c |2 differ|ent DITL|
|00001460| 73 20 7d 0d 09 09 09 09 | 09 09 56 69 65 77 52 65 |s }.....|..ViewRe|
|00001470| 63 74 2c 20 09 7b 73 69 | 7a 65 20 6f 66 20 74 68 |ct, .{si|ze of th|
|00001480| 69 73 20 64 69 61 6c 6f | 67 20 62 6f 78 7d 0d 09 |is dialo|g box}..|
|00001490| 09 09 09 09 09 27 41 62 | 6f 75 74 20 44 69 61 6c |.....'Ab|out Dial|
|000014a0| 6f 67 27 2c 09 7b 74 69 | 74 6c 65 20 6f 66 20 74 |og',.{ti|tle of t|
|000014b0| 68 69 73 20 64 69 61 6c | 6f 67 20 2d 20 75 6e 75 |his dial|og - unu|
|000014c0| 73 65 64 7d 0d 09 09 09 | 09 09 09 54 72 75 65 2c |sed}....|...True,|
|000014d0| 09 09 7b 64 69 61 6c 6f | 67 20 76 69 73 69 62 6c |..{dialo|g visibl|
|000014e0| 65 20 75 70 6f 6e 20 63 | 72 65 61 74 69 6f 6e 7d |e upon c|reation}|
|000014f0| 0d 09 09 09 09 09 09 64 | 42 6f 78 50 72 6f 63 2c |.......d|BoxProc,|
|00001500| 09 7b 6d 6f 64 61 6c 20 | 74 79 70 65 7d 0d 09 09 |.{modal |type}...|
|00001510| 09 09 09 09 50 4f 49 4e | 54 45 52 28 2d 31 29 2c |....POIN|TER(-1),|
|00001520| 09 7b 6d 61 6b 65 20 69 | 74 20 74 68 65 20 66 72 |.{make i|t the fr|
|00001530| 6f 6e 74 6d 6f 73 74 20 | 77 69 6e 64 6f 77 7d 0d |ontmost |window}.|
|00001540| 09 09 09 09 09 09 46 61 | 6c 73 65 2c 09 09 7b 6e |......Fa|lse,..{n|
|00001550| 6f 20 67 6f 41 77 61 79 | 20 62 6f 78 20 69 6e 20 |o goAway| box in |
|00001560| 74 68 65 20 64 69 61 6c | 6f 67 7d 0d 09 09 09 09 |the dial|og}.....|
|00001570| 09 09 30 2c 09 09 09 7b | 52 65 66 43 6f 6e 20 76 |..0,...{|RefCon v|
|00001580| 61 72 69 61 62 6c 65 20 | 69 6e 20 64 69 61 6c 6f |ariable |in dialo|
|00001590| 67 20 72 65 63 6f 72 64 | 7d 0d 09 09 09 09 09 09 |g record|}.......|
|000015a0| 44 49 54 4c 5f 48 64 6c | 29 3b 09 7b 68 61 6e 64 |DITL_Hdl|);.{hand|
|000015b0| 6c 65 20 74 6f 20 74 68 | 65 20 64 69 61 6c 6f 67 |le to th|e dialog|
|000015c0| 20 69 74 65 6d 6c 69 73 | 74 7d 0d 09 09 4d 6f 64 | itemlis|t}...Mod|
|000015d0| 61 6c 44 69 61 6c 6f 67 | 28 6e 69 6c 2c 69 74 65 |alDialog|(nil,ite|
|000015e0| 6d 29 3b 0d 09 09 44 69 | 73 70 6f 73 44 69 61 6c |m);...Di|sposDial|
|000015f0| 6f 67 28 41 62 6f 75 74 | 44 70 74 72 29 3b 0d 09 |og(About|Dptr);..|
|00001600| 09 44 65 74 61 63 68 52 | 65 73 6f 75 72 63 65 28 |.DetachR|esource(|
|00001610| 44 49 54 4c 5f 48 64 6c | 29 3b 0d 09 65 6e 64 3b |DITL_Hdl|);..end;|
|00001620| 0d 45 6e 64 3b 0d 0d 50 | 52 4f 43 45 44 55 52 45 |.End;..P|ROCEDURE|
|00001630| 20 45 6e 74 65 72 54 65 | 78 74 20 28 20 56 41 52 | EnterTe|xt ( VAR|
|00001640| 20 44 65 76 69 63 65 3a | 20 44 65 76 69 63 65 43 | Device:| DeviceC|
|00001650| 6f 6e 74 72 6f 6c 52 65 | 63 29 3b 0d 56 61 72 0d |ontrolRe|c);.Var.|
|00001660| 09 4c 6f 61 64 44 70 74 | 72 09 09 09 3a 20 44 69 |.LoadDpt|r...: Di|
|00001670| 61 6c 6f 67 50 74 72 3b | 0d 09 69 74 65 6d 6e 6f |alogPtr;|..itemno|
|00001680| 2c 20 49 74 65 6d 54 79 | 70 65 09 3a 20 69 6e 74 |, ItemTy|pe.: int|
|00001690| 65 67 65 72 3b 0d 09 49 | 74 65 6d 42 6f 78 09 09 |eger;..I|temBox..|
|000016a0| 09 3a 20 52 65 63 74 3b | 0d 09 49 74 65 6d 48 64 |.: Rect;|..ItemHd|
|000016b0| 6c 09 09 09 3a 20 48 61 | 6e 64 6c 65 3b 0d 09 74 |l...: Ha|ndle;..t|
|000016c0| 68 65 53 74 72 69 6e 67 | 09 09 09 3a 20 53 74 72 |heString|...: Str|
|000016d0| 32 35 35 3b 0d 42 65 67 | 69 6e 0d 09 4c 6f 61 64 |255;.Beg|in..Load|
|000016e0| 44 70 74 72 3a 3d 20 47 | 65 74 4e 65 77 44 69 61 |Dptr:= G|etNewDia|
|000016f0| 6c 6f 67 20 28 64 65 76 | 69 63 65 2e 64 43 74 6c |log (dev|ice.dCtl|
|00001700| 4d 65 6e 75 20 2b 20 31 | 2c 20 4e 69 6c 2c 20 70 |Menu + 1|, Nil, p|
|00001710| 6f 69 6e 74 65 72 28 2d | 31 29 29 3b 0d 09 4d 6f |ointer(-|1));..Mo|
|00001720| 64 61 6c 44 69 61 6c 6f | 67 28 6e 69 6c 2c 20 49 |dalDialo|g(nil, I|
|00001730| 74 65 6d 4e 6f 29 3b 0d | 09 57 69 74 68 20 44 65 |temNo);.|.With De|
|00001740| 76 69 63 65 2e 44 63 74 | 6c 73 74 6f 72 61 67 65 |vice.Dct|lstorage|
|00001750| 5e 5e 20 64 6f 20 62 65 | 67 69 6e 0d 09 09 4e 6f |^^ do be|gin...No|
|00001760| 54 65 78 74 20 3a 3d 20 | 4e 6f 54 65 78 74 20 2b |Text := |NoText +|
|00001770| 20 31 3b 0d 09 09 47 65 | 74 44 49 74 65 6d 28 4c | 1;...Ge|tDItem(L|
|00001780| 6f 61 64 44 70 74 72 2c | 20 32 2c 20 49 74 65 6d |oadDptr,| 2, Item|
|00001790| 54 79 70 65 2c 20 49 74 | 65 6d 48 64 6c 2c 20 49 |Type, It|emHdl, I|
|000017a0| 74 65 6d 42 6f 78 29 3b | 0d 09 09 47 65 74 49 54 |temBox);|...GetIT|
|000017b0| 65 78 74 28 49 74 65 6d | 48 64 6c 2c 20 74 68 65 |ext(Item|Hdl, the|
|000017c0| 53 74 72 69 6e 67 29 3b | 0d 09 09 69 66 20 28 74 |String);|...if (t|
|000017d0| 68 65 53 74 72 69 6e 67 | 20 3d 20 27 27 29 0d 09 |heString| = '')..|
|000017e0| 09 09 74 68 65 6e 20 4e | 6f 54 65 78 74 20 3a 3d |..then N|oText :=|
|000017f0| 20 4e 6f 54 65 78 74 20 | 2d 20 31 0d 09 09 09 65 | NoText |- 1....e|
|00001800| 6c 73 65 20 53 74 72 69 | 6e 67 41 72 72 61 79 5b |lse Stri|ngArray[|
|00001810| 4e 6f 54 65 78 74 5d 20 | 3a 3d 20 63 6f 70 79 20 |NoText] |:= copy |
|00001820| 28 74 68 65 53 74 72 69 | 6e 67 2c 20 31 2c 20 32 |(theStri|ng, 1, 2|
|00001830| 35 29 3b 0d 09 09 65 6e | 64 3b 0d 09 44 69 73 70 |5);...en|d;..Disp|
|00001840| 6f 73 44 69 61 6c 6f 67 | 28 4c 6f 61 64 44 70 74 |osDialog|(LoadDpt|
|00001850| 72 29 3b 0d 45 6e 64 3b | 0d 0d 50 52 4f 43 45 44 |r);.End;|..PROCED|
|00001860| 55 52 45 20 55 70 64 61 | 74 65 44 41 28 56 41 52 |URE Upda|teDA(VAR|
|00001870| 20 64 65 76 69 63 65 3a | 20 44 65 76 69 63 65 43 | device:| DeviceC|
|00001880| 6f 6e 74 72 6f 6c 52 65 | 63 29 3b 09 7b 20 75 70 |ontrolRe|c);.{ up|
|00001890| 64 61 74 65 20 63 61 6c | 6c 20 2d 20 64 72 61 77 |date cal|l - draw|
|000018a0| 20 77 69 6e 64 6f 77 20 | 63 6f 6e 74 65 6e 74 73 | window |contents|
|000018b0| 20 7d 0d 62 65 67 69 6e | 0d 09 77 69 74 68 20 64 | }.begin|..with d|
|000018c0| 65 76 69 63 65 20 64 6f | 20 62 65 67 69 6e 0d 09 |evice do| begin..|
|000018d0| 09 42 65 67 69 6e 55 70 | 64 61 74 65 28 44 69 61 |.BeginUp|date(Dia|
|000018e0| 6c 6f 67 50 74 72 28 64 | 63 74 6c 57 69 6e 64 6f |logPtr(d|ctlWindo|
|000018f0| 77 29 29 3b 0d 09 09 44 | 72 61 77 44 69 61 6c 6f |w));...D|rawDialo|
|00001900| 67 28 44 69 61 6c 6f 67 | 50 74 72 28 64 63 74 6c |g(Dialog|Ptr(dctl|
|00001910| 57 69 6e 64 6f 77 29 29 | 3b 0d 09 09 44 69 74 6c |Window))|;...Ditl|
|00001920| 4c 69 6e 65 73 3b 0d 09 | 09 44 69 74 6c 54 65 78 |Lines;..|.DitlTex|
|00001930| 74 28 64 43 74 6c 53 74 | 6f 72 61 67 65 5e 5e 29 |t(dCtlSt|orage^^)|
|00001940| 3b 0d 09 09 48 69 6c 69 | 74 65 44 65 66 42 75 74 |;...Hili|teDefBut|
|00001950| 74 6f 6e 20 28 44 69 61 | 6c 6f 67 50 74 72 28 64 |ton (Dia|logPtr(d|
|00001960| 63 74 6c 57 69 6e 64 6f | 77 29 29 3b 0d 09 09 45 |ctlWindo|w));...E|
|00001970| 6e 64 55 70 64 61 74 65 | 28 44 69 61 6c 6f 67 50 |ndUpdate|(DialogP|
|00001980| 74 72 28 64 63 74 6c 57 | 69 6e 64 6f 77 29 29 3b |tr(dctlW|indow));|
|00001990| 0d 09 65 6e 64 3b 0d 65 | 6e 64 3b 0d 0d 50 52 4f |..end;.e|nd;..PRO|
|000019a0| 43 45 44 55 52 45 20 44 | 41 61 63 74 69 76 61 74 |CEDURE D|Aactivat|
|000019b0| 65 28 56 41 52 20 64 65 | 76 69 63 65 3a 20 44 65 |e(VAR de|vice: De|
|000019c0| 76 69 63 65 43 6f 6e 74 | 72 6f 6c 52 65 63 29 3b |viceCont|rolRec);|
|000019d0| 09 09 7b 20 61 63 74 69 | 76 61 74 65 20 63 61 6c |..{ acti|vate cal|
|000019e0| 6c 20 2d 20 70 75 74 20 | 6d 65 6e 75 20 6f 6e 20 |l - put |menu on |
|000019f0| 6d 65 6e 75 20 62 61 72 | 20 7d 0d 62 65 67 69 6e |menu bar| }.begin|
|00001a00| 0d 09 77 69 74 68 20 64 | 65 76 69 63 65 20 64 6f |..with d|evice do|
|00001a10| 0d 09 09 77 69 74 68 20 | 64 43 74 6c 53 74 6f 72 |...with |dCtlStor|
|00001a20| 61 67 65 5e 5e 20 64 6f | 20 62 65 67 69 6e 0d 09 |age^^ do| begin..|
|00001a30| 09 09 6d 65 6e 75 48 61 | 6e 64 5e 5e 2e 6d 65 6e |..menuHa|nd^^.men|
|00001a40| 75 49 44 20 3a 3d 20 44 | 43 74 6c 4d 65 6e 75 3b |uID := D|CtlMenu;|
|00001a50| 0d 09 09 09 49 6e 73 65 | 72 74 4d 65 6e 75 20 28 |....Inse|rtMenu (|
|00001a60| 6d 65 6e 75 48 61 6e 64 | 2c 30 29 3b 0d 09 09 09 |menuHand|,0);....|
|00001a70| 44 72 61 77 4d 65 6e 75 | 42 61 72 3b 0d 09 09 65 |DrawMenu|Bar;...e|
|00001a80| 6e 64 3b 0d 65 6e 64 3b | 0d 0d 50 52 4f 43 45 44 |nd;.end;|..PROCED|
|00001a90| 55 52 45 20 44 41 64 65 | 61 63 74 69 76 61 74 65 |URE DAde|activate|
|00001aa0| 28 56 41 52 20 64 65 76 | 69 63 65 3a 20 44 65 76 |(VAR dev|ice: Dev|
|00001ab0| 69 63 65 43 6f 6e 74 72 | 6f 6c 52 65 63 29 3b 20 |iceContr|olRec); |
|00001ac0| 20 20 7b 20 64 65 61 63 | 74 69 76 61 74 65 20 2d | { deac|tivate -|
|00001ad0| 20 72 65 6d 6f 76 65 20 | 6d 65 6e 75 20 66 72 6f | remove |menu fro|
|00001ae0| 6d 20 6d 65 6e 75 20 62 | 61 72 20 7d 0d 62 65 67 |m menu b|ar }.beg|
|00001af0| 69 6e 0d 09 44 65 6c 65 | 74 65 4d 65 6e 75 28 44 |in..Dele|teMenu(D|
|00001b00| 65 76 69 63 65 2e 44 43 | 74 6c 4d 65 6e 75 29 3b |evice.DC|tlMenu);|
|00001b10| 0d 09 44 72 61 77 4d 65 | 6e 75 42 61 72 3b 0d 65 |..DrawMe|nuBar;.e|
|00001b20| 6e 64 3b 09 7b 20 6f 66 | 20 44 41 64 65 61 63 74 |nd;.{ of| DAdeact|
|00001b30| 69 76 61 74 65 20 7d 0d | 0d 50 52 4f 43 45 44 55 |ivate }.|.PROCEDU|
|00001b40| 52 45 20 43 74 6c 52 61 | 64 69 6f 42 75 74 74 6f |RE CtlRa|dioButto|
|00001b50| 6e 73 20 28 56 41 52 20 | 44 65 76 69 63 65 20 3a |ns (VAR |Device :|
|00001b60| 20 44 65 76 69 63 65 43 | 6f 6e 74 72 6f 6c 52 65 | DeviceC|ontrolRe|
|00001b70| 63 3b 20 57 68 69 63 68 | 42 75 74 74 6f 6e 20 3a |c; Which|Button :|
|00001b80| 20 69 6e 74 65 67 65 72 | 29 3b 0d 42 65 67 69 6e | integer|);.Begin|
|00001b90| 0d 09 77 69 74 68 20 64 | 65 76 69 63 65 2e 64 63 |..with d|evice.dc|
|00001ba0| 74 6c 73 74 6f 72 61 67 | 65 5e 5e 20 64 6f 20 62 |tlstorag|e^^ do b|
|00001bb0| 65 67 69 6e 0d 09 09 53 | 65 74 52 61 64 69 6f 42 |egin...S|etRadioB|
|00001bc0| 75 74 74 6f 6e 20 28 44 | 65 76 69 63 65 2e 44 43 |utton (D|evice.DC|
|00001bd0| 74 6c 57 69 6e 64 6f 77 | 2c 20 42 75 74 74 6f 6e |tlWindow|, Button|
|00001be0| 4e 6f 20 2b 20 35 2c 20 | 63 68 6b 5f 6f 66 66 29 |No + 5, |chk_off)|
|00001bf0| 3b 0d 09 09 53 65 74 52 | 61 64 69 6f 42 75 74 74 |;...SetR|adioButt|
|00001c00| 6f 6e 20 28 44 65 76 69 | 63 65 2e 44 43 74 6c 57 |on (Devi|ce.DCtlW|
|00001c10| 69 6e 64 6f 77 2c 20 57 | 68 69 63 68 42 75 74 74 |indow, W|hichButt|
|00001c20| 6f 6e 20 2b 20 35 2c 20 | 43 68 6b 5f 4f 6e 29 3b |on + 5, |Chk_On);|
|00001c30| 0d 09 09 42 75 74 74 6f | 6e 4e 6f 20 3a 3d 20 57 |...Butto|nNo := W|
|00001c40| 68 69 63 68 42 75 74 74 | 6f 6e 3b 0d 09 65 6e 64 |hichButt|on;..end|
|00001c50| 3b 0d 45 6e 64 3b 0d 0d | 50 52 4f 43 45 44 55 52 |;.End;..|PROCEDUR|
|00001c60| 45 20 44 6f 44 65 66 42 | 75 74 74 6f 6e 28 56 41 |E DoDefB|utton(VA|
|00001c70| 52 20 44 65 76 69 63 65 | 3a 20 44 65 76 69 63 65 |R Device|: Device|
|00001c80| 43 6f 6e 74 72 6f 6c 52 | 65 63 29 3b 0d 56 61 72 |ControlR|ec);.Var|
|00001c90| 0d 09 4e 75 6d 4f 6e 65 | 2c 20 4e 75 6d 54 77 6f |..NumOne|, NumTwo|
|00001ca0| 09 3a 20 6c 6f 6e 67 69 | 6e 74 3b 0d 09 42 69 67 |.: longi|nt;..Big|
|00001cb0| 52 65 63 09 09 3a 20 72 | 65 63 74 3b 0d 42 65 67 |Rec..: r|ect;.Beg|
|00001cc0| 69 6e 0d 09 77 69 74 68 | 20 64 65 76 69 63 65 20 |in..with| device |
|00001cd0| 64 6f 20 62 65 67 69 6e | 0d 09 09 53 65 74 52 65 |do begin|...SetRe|
|00001ce0| 63 74 28 42 69 67 52 65 | 63 2c 2d 39 39 39 2c 2d |ct(BigRe|c,-999,-|
|00001cf0| 39 39 39 2c 39 39 39 2c | 39 39 39 29 3b 0d 09 09 |999,999,|999);...|
|00001d00| 49 74 65 6d 41 63 74 69 | 76 61 74 65 20 28 44 43 |ItemActi|vate (DC|
|00001d10| 74 6c 57 69 6e 64 6f 77 | 2c 20 52 65 73 65 74 42 |tlWindow|, ResetB|
|00001d20| 75 74 74 6f 6e 2c 20 43 | 4e 54 4c 5f 65 6e 61 62 |utton, C|NTL_enab|
|00001d30| 6c 65 29 3b 0d 09 09 4e | 75 6d 4f 6e 65 20 3a 3d |le);...N|umOne :=|
|00001d40| 20 47 65 74 54 78 74 56 | 61 6c 75 65 28 64 63 74 | GetTxtV|alue(dct|
|00001d50| 6c 57 69 6e 64 6f 77 2c | 20 54 62 6f 78 29 3b 0d |lWindow,| Tbox);.|
|00001d60| 09 09 4e 75 6d 54 77 6f | 20 3a 3d 20 47 65 74 54 |..NumTwo| := GetT|
|00001d70| 78 74 56 61 6c 75 65 28 | 64 63 74 6c 57 69 6e 64 |xtValue(|dctlWind|
|00001d80| 6f 77 2c 20 54 62 6f 78 | 49 49 29 3b 0d 09 09 64 |ow, Tbox|II);...d|
|00001d90| 63 74 6c 73 74 6f 72 61 | 67 65 5e 5e 2e 4e 75 6d |ctlstora|ge^^.Num|
|00001da0| 62 65 72 20 3a 3d 20 4e | 75 6d 4f 6e 65 20 20 2a |ber := N|umOne *|
|00001db0| 20 4e 75 6d 54 77 6f 3b | 0d 09 09 45 72 61 73 65 | NumTwo;|...Erase|
|00001dc0| 52 65 63 74 28 42 69 67 | 52 65 63 29 3b 0d 09 09 |Rect(Big|Rec);...|
|00001dd0| 49 6e 76 61 6c 52 65 63 | 74 28 42 69 67 52 65 63 |InvalRec|t(BigRec|
|00001de0| 29 3b 09 7b 66 6f 72 63 | 65 20 75 70 64 61 74 65 |);.{forc|e update|
|00001df0| 7d 0d 09 65 6e 64 3b 0d | 45 6e 64 3b 0d 0d 50 52 |}..end;.|End;..PR|
|00001e00| 4f 43 45 44 55 52 45 20 | 44 6f 52 65 73 65 74 42 |OCEDURE |DoResetB|
|00001e10| 75 74 74 6f 6e 28 56 41 | 52 20 44 65 76 69 63 65 |utton(VA|R Device|
|00001e20| 3a 20 44 65 76 69 63 65 | 43 6f 6e 74 72 6f 6c 52 |: Device|ControlR|
|00001e30| 65 63 29 3b 0d 56 61 72 | 0d 09 42 69 67 52 65 63 |ec);.Var|..BigRec|
|00001e40| 09 09 3a 20 72 65 63 74 | 3b 0d 42 65 67 69 6e 0d |..: rect|;.Begin.|
|00001e50| 09 53 65 74 52 65 63 74 | 28 42 69 67 52 65 63 2c |.SetRect|(BigRec,|
|00001e60| 2d 39 39 39 2c 2d 39 39 | 39 2c 39 39 39 2c 39 39 |-999,-99|9,999,99|
|00001e70| 39 29 3b 0d 09 49 6e 69 | 74 44 6c 6f 67 53 74 61 |9);..Ini|tDlogSta|
|00001e80| 74 75 73 28 64 65 76 69 | 63 65 29 3b 0d 09 45 72 |tus(devi|ce);..Er|
|00001e90| 61 73 65 52 65 63 74 28 | 42 69 67 52 65 63 29 3b |aseRect(|BigRec);|
|00001ea0| 0d 09 49 6e 76 61 6c 52 | 65 63 74 28 42 69 67 52 |..InvalR|ect(BigR|
|00001eb0| 65 63 29 3b 09 7b 66 6f | 72 63 65 20 75 70 64 61 |ec);.{fo|rce upda|
|00001ec0| 74 65 7d 0d 45 6e 64 3b | 0d 0d 50 52 4f 43 45 44 |te}.End;|..PROCED|
|00001ed0| 55 52 45 20 44 6f 54 69 | 6d 65 42 75 74 74 6f 6e |URE DoTi|meButton|
|00001ee0| 28 56 41 52 20 44 65 76 | 69 63 65 3a 20 44 65 76 |(VAR Dev|ice: Dev|
|00001ef0| 69 63 65 43 6f 6e 74 72 | 6f 6c 52 65 63 29 3b 0d |iceContr|olRec);.|
|00001f00| 56 61 72 0d 09 4f 53 45 | 72 72 09 09 09 09 3a 20 |Var..OSE|rr....: |
|00001f10| 69 6e 74 65 67 65 72 3b | 0d 09 44 69 73 6d 69 73 |integer;|..Dismis|
|00001f20| 73 49 74 65 6d 09 09 09 | 3a 20 6c 6f 6e 67 69 6e |sItem...|: longin|
|00001f30| 74 3b 0d 09 54 69 6d 65 | 41 64 6a 75 73 74 2c 20 |t;..Time|Adjust, |
|00001f40| 54 69 6d 65 49 6e 53 65 | 63 09 3a 20 6c 6f 6e 67 |TimeInSe|c.: long|
|00001f50| 69 6e 74 3b 0d 42 65 67 | 69 6e 0d 09 44 69 73 6d |int;.Beg|in..Dism|
|00001f60| 69 73 73 49 74 65 6d 20 | 3a 3d 20 41 6c 65 72 74 |issItem |:= Alert|
|00001f70| 28 64 65 76 69 63 65 2e | 64 43 74 6c 4d 65 6e 75 |(device.|dCtlMenu|
|00001f80| 20 2b 20 31 2c 20 6e 69 | 6c 29 3b 0d 09 54 69 6d | + 1, ni|l);..Tim|
|00001f90| 65 41 64 6a 75 73 74 20 | 3a 3d 20 30 3b 0d 09 63 |eAdjust |:= 0;..c|
|00001fa0| 61 73 65 20 44 69 73 6d | 69 73 73 49 74 65 6d 20 |ase Dism|issItem |
|00001fb0| 6f 66 0d 09 09 32 3a 09 | 54 69 6d 65 41 64 6a 75 |of...2:.|TimeAdju|
|00001fc0| 73 74 20 3a 3d 20 33 36 | 30 30 3b 0d 09 09 33 3a |st := 36|00;...3:|
|00001fd0| 09 54 69 6d 65 41 64 6a | 75 73 74 20 3a 3d 20 2d |.TimeAdj|ust := -|
|00001fe0| 33 36 30 30 3b 0d 09 09 | 65 6e 64 3b 0d 09 47 65 |3600;...|end;..Ge|
|00001ff0| 74 44 61 74 65 54 69 6d | 65 20 28 54 69 6d 65 49 |tDateTim|e (TimeI|
|00002000| 6e 53 65 63 29 3b 0d 09 | 4f 53 45 72 72 20 3a 3d |nSec);..|OSErr :=|
|00002010| 20 53 65 74 44 61 74 65 | 54 69 6d 65 20 28 54 69 | SetDate|Time (Ti|
|00002020| 6d 65 49 6e 53 65 63 20 | 2b 20 54 69 6d 65 41 64 |meInSec |+ TimeAd|
|00002030| 6a 75 73 74 29 3b 0d 45 | 6e 64 3b 0d 0d 50 52 4f |just);.E|nd;..PRO|
|00002040| 43 45 44 55 52 45 20 64 | 6f 4b 65 79 45 76 65 6e |CEDURE d|oKeyEven|
|00002050| 74 20 28 56 41 52 20 44 | 65 76 69 63 65 20 3a 20 |t (VAR D|evice : |
|00002060| 44 65 76 69 63 65 43 6f | 6e 74 72 6f 6c 52 65 63 |DeviceCo|ntrolRec|
|00002070| 3b 20 45 76 65 6e 74 50 | 74 72 20 3a 20 45 76 65 |; EventP|tr : Eve|
|00002080| 6e 74 50 6f 69 6e 74 65 | 72 29 3b 0d 43 6f 6e 73 |ntPointe|r);.Cons|
|00002090| 74 09 09 7b 6b 65 79 20 | 63 6f 64 65 73 7d 0d 09 |t..{key |codes}..|
|000020a0| 43 6d 64 54 09 3d 20 24 | 37 34 3b 09 09 52 65 74 |CmdT.= $|74;..Ret|
|000020b0| 75 72 6e 09 3d 20 24 30 | 33 3b 09 09 5a 65 72 6f |urn.= $0|3;..Zero|
|000020c0| 09 3d 20 24 33 30 3b 0d | 09 43 6d 64 52 09 3d 20 |.= $30;.|.CmdR.= |
|000020d0| 24 37 32 3b 09 09 45 6e | 74 65 72 09 3d 20 24 30 |$72;..En|ter.= $0|
|000020e0| 44 3b 09 09 4e 69 6e 65 | 09 3d 20 24 33 39 3b 0d |D;..Nine|.= $39;.|
|000020f0| 09 43 6d 64 51 09 3d 20 | 24 37 31 3b 09 09 54 61 |.CmdQ.= |$71;..Ta|
|00002100| 62 09 09 3d 20 24 30 39 | 3b 0d 09 43 6d 64 42 09 |b..= $09|;..CmdB.|
|00002110| 3d 20 24 36 32 3b 09 09 | 42 61 63 6b 73 70 61 63 |= $62;..|Backspac|
|00002120| 65 20 3d 20 24 30 38 3b | 0d 56 61 72 0d 09 69 74 |e = $08;|.Var..it|
|00002130| 65 6d 2c 20 63 68 61 72 | 43 6f 64 65 20 3a 20 69 |em, char|Code : i|
|00002140| 6e 74 65 67 65 72 3b 0d | 09 74 6d 70 44 50 74 72 |nteger;.|.tmpDPtr|
|00002150| 09 09 3a 20 44 69 61 6c | 6f 67 50 74 72 3b 0d 09 |..: Dial|ogPtr;..|
|00002160| 61 46 6c 61 67 09 09 3a | 20 62 6f 6f 6c 65 61 6e |aFlag..:| boolean|
|00002170| 3b 09 7b 20 75 73 65 64 | 20 61 73 20 64 75 6d 6d |;.{ used| as dumm|
|00002180| 79 20 76 61 72 69 61 62 | 6c 65 20 69 6e 20 63 61 |y variab|le in ca|
|00002190| 6c 6c 69 6e 67 20 44 69 | 61 6c 6f 67 53 65 6c 65 |lling Di|alogSele|
|000021a0| 63 74 20 7d 0d 09 42 75 | 74 4e 75 6d 09 09 3a 20 |ct }..Bu|tNum..: |
|000021b0| 6c 6f 6e 67 69 6e 74 3b | 09 09 7b 20 75 73 65 64 |longint;|..{ used|
|000021c0| 20 74 6f 20 73 65 74 20 | 62 75 74 74 6f 6e 20 69 | to set |button i|
|000021d0| 6e 20 43 74 6c 52 61 64 | 69 6f 42 75 74 74 6f 6e |n CtlRad|ioButton|
|000021e0| 2c 20 26 20 69 6e 20 44 | 65 6c 61 79 20 63 61 6c |, & in D|elay cal|
|000021f0| 6c 20 7d 0d 42 65 67 69 | 6e 0d 09 77 69 74 68 20 |l }.Begi|n..with |
|00002200| 45 76 65 6e 74 50 74 72 | 5e 20 64 6f 0d 09 09 77 |EventPtr|^ do...w|
|00002210| 69 74 68 20 64 65 76 69 | 63 65 2e 64 63 74 6c 73 |ith devi|ce.dctls|
|00002220| 74 6f 72 61 67 65 5e 5e | 20 64 6f 20 62 65 67 69 |torage^^| do begi|
|00002230| 6e 0d 09 09 09 63 68 61 | 72 43 6f 64 65 20 3a 3d |n....cha|rCode :=|
|00002240| 20 42 69 74 41 6e 64 28 | 6d 65 73 73 61 67 65 2c | BitAnd(|message,|
|00002250| 20 63 68 61 72 43 6f 64 | 65 4d 61 73 6b 29 3b 0d | charCod|eMask);.|
|00002260| 09 09 09 69 66 20 42 69 | 74 41 6e 64 20 28 6d 6f |...if Bi|tAnd (mo|
|00002270| 64 69 66 69 65 72 73 2c | 20 63 6d 64 4b 65 79 29 |difiers,| cmdKey)|
|00002280| 20 3c 3e 20 30 0d 09 09 | 09 09 74 68 65 6e 20 63 | <> 0...|..then c|
|00002290| 61 73 65 20 63 68 61 72 | 43 6f 64 65 20 6f 66 09 |ase char|Code of.|
|000022a0| 09 7b 20 3d 3d 3d 3d 3d | 3d 20 66 69 65 6c 64 20 |.{ =====|= field |
|000022b0| 61 6c 6c 6f 77 61 62 6c | 65 20 63 6f 6d 6d 61 6e |allowabl|e comman|
|000022c0| 64 20 6b 65 79 73 20 3d | 3d 3d 3d 3d 3d 20 7d 0d |d keys =|===== }.|
|000022d0| 09 09 09 09 09 43 6d 64 | 42 3a 09 7b 20 72 6f 74 |.....Cmd|B:.{ rot|
|000022e0| 61 74 65 20 72 61 64 69 | 6f 20 62 75 74 74 6f 6e |ate radi|o button|
|000022f0| 73 20 7d 0d 09 09 09 09 | 09 09 62 65 67 69 6e 0d |s }.....|..begin.|
|00002300| 09 09 09 09 09 09 09 69 | 66 20 28 42 75 74 74 6f |.......i|f (Butto|
|00002310| 6e 4e 6f 20 3d 20 33 29 | 0d 09 09 09 09 09 09 09 |nNo = 3)|........|
|00002320| 09 74 68 65 6e 20 42 75 | 74 4e 75 6d 20 3a 3d 20 |.then Bu|tNum := |
|00002330| 31 0d 09 09 09 09 09 09 | 09 09 65 6c 73 65 20 42 |1.......|..else B|
|00002340| 75 74 4e 75 6d 20 3a 3d | 20 42 75 74 74 6f 6e 4e |utNum :=| ButtonN|
|00002350| 6f 20 2b 20 31 3b 0d 09 | 09 09 09 09 09 09 43 74 |o + 1;..|......Ct|
|00002360| 6c 52 61 64 69 6f 42 75 | 74 74 6f 6e 73 20 28 44 |lRadioBu|ttons (D|
|00002370| 65 76 69 63 65 2c 20 42 | 75 74 4e 75 6d 29 3b 0d |evice, B|utNum);.|
|00002380| 09 09 09 09 09 09 65 6e | 64 3b 0d 09 09 09 09 09 |......en|d;......|
|00002390| 43 6d 64 52 3a 0d 09 09 | 09 09 09 09 44 6f 52 65 |CmdR:...|....DoRe|
|000023a0| 73 65 74 42 75 74 74 6f | 6e 28 64 65 76 69 63 65 |setButto|n(device|
|000023b0| 29 3b 0d 09 09 09 09 09 | 43 6d 64 54 3a 0d 09 09 |);......|CmdT:...|
|000023c0| 09 09 09 09 44 6f 54 69 | 6d 65 42 75 74 74 6f 6e |....DoTi|meButton|
|000023d0| 28 64 65 76 69 63 65 29 | 3b 0d 09 09 09 09 09 43 |(device)|;......C|
|000023e0| 6d 64 51 3a 20 7b 20 51 | 75 69 74 20 7d 0d 09 09 |mdQ: { Q|uit }...|
|000023f0| 09 09 09 09 46 69 6e 69 | 73 68 65 64 20 3a 3d 20 |....Fini|shed := |
|00002400| 54 72 75 65 3b 0d 09 09 | 09 09 09 6f 74 68 65 72 |True;...|...other|
|00002410| 77 69 73 65 0d 09 09 09 | 09 09 09 53 79 73 62 65 |wise....|...Sysbe|
|00002420| 65 70 28 31 29 3b 09 7b | 20 69 67 6e 6f 72 65 20 |ep(1);.{| ignore |
|00002430| 61 6c 6c 20 6f 74 68 65 | 72 20 63 6f 6d 6d 61 6e |all othe|r comman|
|00002440| 64 20 6b 65 79 73 20 7d | 0d 09 09 09 09 09 65 6e |d keys }|......en|
|00002450| 64 09 09 7b 6f 66 20 63 | 61 73 65 7d 0d 09 09 09 |d..{of c|ase}....|
|00002460| 09 65 6c 73 65 20 62 65 | 67 69 6e 09 09 09 09 09 |.else be|gin.....|
|00002470| 7b 20 3d 3d 3d 3d 3d 3d | 3d 3d 20 68 61 6e 64 6c |{ ======|== handl|
|00002480| 65 20 61 6c 6c 20 6f 74 | 68 65 72 20 6b 65 79 73 |e all ot|her keys|
|00002490| 20 3d 3d 3d 3d 3d 3d 3d | 3d 20 7d 0d 09 09 09 09 | =======|= }.....|
|000024a0| 09 69 66 20 28 63 68 61 | 72 43 6f 64 65 20 3e 3d |.if (cha|rCode >=|
|000024b0| 20 5a 65 72 6f 29 20 61 | 6e 64 20 28 63 68 61 72 | Zero) a|nd (char|
|000024c0| 43 6f 64 65 20 3c 3d 20 | 4e 69 6e 65 29 09 7b 20 |Code <= |Nine).{ |
|000024d0| 3d 3d 3d 61 6c 6c 6f 77 | 20 6e 75 6d 65 72 69 63 |===allow| numeric|
|000024e0| 20 6b 65 79 73 3d 3d 3d | 20 7d 0d 09 09 09 09 09 | keys===| }......|
|000024f0| 09 74 68 65 6e 20 61 46 | 6c 61 67 20 3a 3d 20 44 |.then aF|lag := D|
|00002500| 69 61 6c 6f 67 53 65 6c | 65 63 74 20 28 45 76 65 |ialogSel|ect (Eve|
|00002510| 6e 74 50 74 72 5e 2c 20 | 74 6d 70 44 70 74 72 2c |ntPtr^, |tmpDptr,|
|00002520| 20 69 74 65 6d 29 0d 09 | 09 09 09 09 09 65 6c 73 | item)..|.....els|
|00002530| 65 20 63 61 73 65 20 63 | 68 61 72 63 6f 64 65 20 |e case c|harcode |
|00002540| 6f 66 09 7b 20 3d 3d 3d | 3d 3d 20 61 6c 6c 6f 77 |of.{ ===|== allow|
|00002550| 20 73 6f 6d 65 20 6e 6f | 6e 2d 6e 75 6d 65 72 69 | some no|n-numeri|
|00002560| 63 20 6b 65 79 73 3d 3d | 3d 3d 3d 20 7d 0d 09 09 |c keys==|=== }...|
|00002570| 09 09 09 09 09 52 65 74 | 75 72 6e 2c 20 45 6e 74 |.....Ret|urn, Ent|
|00002580| 65 72 3a 0d 09 09 09 09 | 09 09 09 09 62 65 67 69 |er:.....|....begi|
|00002590| 6e 0d 09 09 09 09 09 09 | 09 09 09 49 74 65 6d 41 |n.......|...ItemA|
|000025a0| 63 74 69 76 61 74 65 20 | 28 44 65 76 69 63 65 2e |ctivate |(Device.|
|000025b0| 44 43 74 6c 57 69 6e 64 | 6f 77 2c 20 44 65 66 62 |DCtlWind|ow, Defb|
|000025c0| 75 74 74 6f 6e 2c 20 69 | 6e 42 75 74 74 6f 6e 29 |utton, i|nButton)|
|000025d0| 3b 0d 09 09 09 09 09 09 | 09 09 09 44 65 6c 61 79 |;.......|...Delay|
|000025e0| 28 31 35 2c 20 42 75 74 | 4e 75 6d 29 3b 0d 09 09 |(15, But|Num);...|
|000025f0| 09 09 09 09 09 09 09 49 | 74 65 6d 41 63 74 69 76 |.......I|temActiv|
|00002600| 61 74 65 20 28 44 65 76 | 69 63 65 2e 44 43 74 6c |ate (Dev|ice.DCtl|
|00002610| 57 69 6e 64 6f 77 2c 20 | 44 65 66 62 75 74 74 6f |Window, |Defbutto|
|00002620| 6e 2c 20 43 4e 54 4c 5f | 65 6e 61 62 6c 65 29 3b |n, CNTL_|enable);|
|00002630| 0d 09 09 09 09 09 09 09 | 09 09 44 6f 44 65 66 42 |........|..DoDefB|
|00002640| 75 74 74 6f 6e 28 64 65 | 76 69 63 65 29 3b 0d 09 |utton(de|vice);..|
|00002650| 09 09 09 09 09 09 09 65 | 6e 64 3b 0d 09 09 09 09 |.......e|nd;.....|
|00002660| 09 09 09 54 61 62 2c 20 | 42 61 63 6b 73 70 61 63 |...Tab, |Backspac|
|00002670| 65 3a 0d 09 09 09 09 09 | 09 09 09 61 46 6c 61 67 |e:......|...aFlag|
|00002680| 20 3a 3d 20 44 69 61 6c | 6f 67 53 65 6c 65 63 74 | := Dial|ogSelect|
|00002690| 20 28 45 76 65 6e 74 50 | 74 72 5e 2c 20 74 6d 70 | (EventP|tr^, tmp|
|000026a0| 44 70 74 72 2c 20 69 74 | 65 6d 29 3b 0d 09 09 09 |Dptr, it|em);....|
|000026b0| 09 09 09 09 6f 74 68 65 | 72 77 69 73 65 0d 09 09 |....othe|rwise...|
|000026c0| 09 09 09 09 09 09 53 79 | 73 62 65 65 70 28 31 29 |......Sy|sbeep(1)|
|000026d0| 3b 09 7b 20 69 67 6e 6f | 72 65 20 61 6c 6c 20 6f |;.{ igno|re all o|
|000026e0| 74 68 65 72 20 6b 65 79 | 73 20 7d 0d 09 09 09 09 |ther key|s }.....|
|000026f0| 09 09 65 6e 64 3b 20 20 | 7b 20 6f 66 20 63 61 73 |..end; |{ of cas|
|00002700| 65 20 63 68 61 72 63 6f | 64 65 20 2d 20 6e 6f 6e |e charco|de - non|
|00002710| 2d 6e 75 6d 65 72 69 63 | 20 6b 65 79 73 20 7d 0d |-numeric| keys }.|
|00002720| 09 09 09 09 09 65 6e 64 | 3b 20 20 7b 20 6f 66 20 |.....end|; { of |
|00002730| 6e 6f 6e 2d 63 6f 6d 6d | 61 6e 64 20 6b 65 79 73 |non-comm|and keys|
|00002740| 20 7d 0d 09 09 65 6e 64 | 3b 20 20 7b 20 77 69 74 | }...end|; { wit|
|00002750| 68 20 64 65 76 69 63 65 | 2e 64 63 74 6c 73 74 6f |h device|.dctlsto|
|00002760| 72 61 67 65 5e 5e 20 7d | 0d 45 6e 64 3b 0d 0d 50 |rage^^ }|.End;..P|
|00002770| 52 4f 43 45 44 55 52 45 | 20 45 76 65 6e 74 28 56 |ROCEDURE| Event(V|
|00002780| 41 52 20 44 65 76 69 63 | 65 09 3a 20 44 65 76 69 |AR Devic|e.: Devi|
|00002790| 63 65 43 6f 6e 74 72 6f | 6c 52 65 63 3b 0d 09 09 |ceContro|lRec;...|
|000027a0| 09 20 20 20 20 56 41 52 | 20 42 6c 6f 63 6b 09 3a |. VAR| Block.:|
|000027b0| 20 50 61 72 61 6d 42 6c | 6f 63 6b 52 65 63 29 3b | ParamBl|ockRec);|
|000027c0| 0d 56 61 72 0d 09 69 74 | 65 6d 2c 20 44 69 73 6d |.Var..it|em, Dism|
|000027d0| 69 73 73 49 74 65 6d 09 | 3a 20 69 6e 74 65 67 65 |issItem.|: intege|
|000027e0| 72 3b 0d 09 74 6d 70 44 | 50 74 72 09 09 09 3a 20 |r;..tmpD|Ptr...: |
|000027f0| 44 69 61 6c 6f 67 50 74 | 72 3b 0d 09 45 76 65 6e |DialogPt|r;..Even|
|00002800| 74 50 74 72 09 09 09 3a | 20 45 76 65 6e 74 50 6f |tPtr...:| EventPo|
|00002810| 69 6e 74 65 72 3b 0d 09 | 61 46 6c 61 67 09 09 09 |inter;..|aFlag...|
|00002820| 3a 20 62 6f 6f 6c 65 61 | 6e 3b 09 7b 20 75 73 65 |: boolea|n;.{ use|
|00002830| 64 20 61 73 20 64 75 6d | 6d 79 20 76 61 72 69 61 |d as dum|my varia|
|00002840| 62 6c 65 20 69 6e 20 63 | 61 6c 6c 69 6e 67 20 44 |ble in c|alling D|
|00002850| 69 61 6c 6f 67 53 65 6c | 65 63 74 20 7d 0d 09 6c |ialogSel|ect }..l|
|00002860| 61 73 74 56 61 6c 09 09 | 09 3a 20 6c 6f 6e 67 69 |astVal..|.: longi|
|00002870| 6e 74 3b 09 09 7b 20 75 | 73 65 64 20 61 73 20 64 |nt;..{ u|sed as d|
|00002880| 75 6d 6d 79 20 76 61 72 | 69 61 62 6c 65 20 69 6e |ummy var|iable in|
|00002890| 20 44 45 4c 41 59 20 70 | 72 6f 63 20 7d 0d 42 65 | DELAY p|roc }.Be|
|000028a0| 67 69 6e 0d 09 62 6c 6f | 63 6b 4d 6f 76 65 28 40 |gin..blo|ckMove(@|
|000028b0| 62 6c 6f 63 6b 2e 63 73 | 50 61 72 61 6d 5b 30 5d |block.cs|Param[0]|
|000028c0| 2c 40 45 76 65 6e 74 50 | 74 72 2c 34 29 3b 0d 09 |,@EventP|tr,4);..|
|000028d0| 77 69 74 68 20 64 65 76 | 69 63 65 2e 64 63 74 6c |with dev|ice.dctl|
|000028e0| 73 74 6f 72 61 67 65 5e | 5e 20 64 6f 20 62 65 67 |storage^|^ do beg|
|000028f0| 69 6e 0d 09 09 63 61 73 | 65 20 45 76 65 6e 74 50 |in...cas|e EventP|
|00002900| 74 72 5e 2e 77 68 61 74 | 20 6f 66 0d 09 09 09 4d |tr^.what| of....M|
|00002910| 6f 75 73 65 44 6f 77 6e | 3a 0d 09 09 09 09 62 65 |ouseDown|:.....be|
|00002920| 67 69 6e 0d 09 09 09 09 | 69 66 20 44 69 61 6c 6f |gin.....|if Dialo|
|00002930| 67 53 65 6c 65 63 74 20 | 28 45 76 65 6e 74 50 74 |gSelect |(EventPt|
|00002940| 72 5e 2c 20 74 6d 70 44 | 70 74 72 2c 20 69 74 65 |r^, tmpD|ptr, ite|
|00002950| 6d 29 20 74 68 65 6e 09 | 7b 20 70 72 6f 63 65 73 |m) then.|{ proces|
|00002960| 73 20 69 66 20 69 74 65 | 6d 20 69 73 20 65 6e 61 |s if ite|m is ena|
|00002970| 62 6c 65 64 20 7d 0d 09 | 09 09 09 09 63 61 73 65 |bled }..|....case|
|00002980| 20 49 74 65 6d 20 6f 66 | 0d 09 09 09 09 09 09 44 | Item of|.......D|
|00002990| 65 66 62 75 74 74 6f 6e | 3a 0d 09 09 09 09 09 09 |efbutton|:.......|
|000029a0| 09 44 6f 44 65 66 42 75 | 74 74 6f 6e 28 64 65 76 |.DoDefBu|tton(dev|
|000029b0| 69 63 65 29 3b 0d 09 09 | 09 09 09 09 41 62 6f 75 |ice);...|....Abou|
|000029c0| 74 62 75 74 74 6f 6e 3a | 0d 09 09 09 09 09 09 09 |tbutton:|........|
|000029d0| 44 6f 41 62 6f 75 74 28 | 64 65 76 69 63 65 2e 64 |DoAbout(|device.d|
|000029e0| 63 74 6c 4d 65 6e 75 20 | 2b 20 31 29 3b 0d 09 09 |ctlMenu |+ 1);...|
|000029f0| 09 09 09 09 51 75 69 74 | 42 75 74 74 6f 6e 3a 0d |....Quit|Button:.|
|00002a00| 09 09 09 09 09 09 09 46 | 69 6e 69 73 68 65 64 20 |.......F|inished |
|00002a10| 3a 3d 20 54 72 75 65 3b | 0d 09 09 09 09 09 09 52 |:= True;|.......R|
|00002a20| 65 73 65 74 42 75 74 74 | 6f 6e 3a 0d 09 09 09 09 |esetButt|on:.....|
|00002a30| 09 09 09 44 6f 52 65 73 | 65 74 42 75 74 74 6f 6e |...DoRes|etButton|
|00002a40| 28 64 65 76 69 63 65 29 | 3b 0d 09 09 09 09 09 09 |(device)|;.......|
|00002a50| 54 69 6d 65 42 75 74 74 | 6f 6e 3a 0d 09 09 09 09 |TimeButt|on:.....|
|00002a60| 09 09 09 44 6f 54 69 6d | 65 42 75 74 74 6f 6e 28 |...DoTim|eButton(|
|00002a70| 64 65 76 69 63 65 29 3b | 0d 09 09 09 09 09 09 42 |device);|.......B|
|00002a80| 75 6c 6c 73 49 43 4f 4e | 3a 0d 09 09 09 09 09 09 |ullsICON|:.......|
|00002a90| 09 44 69 73 6d 69 73 73 | 49 74 65 6d 20 3a 3d 20 |.Dismiss|Item := |
|00002aa0| 41 6c 65 72 74 28 64 65 | 76 69 63 65 2e 64 43 74 |Alert(de|vice.dCt|
|00002ab0| 6c 4d 65 6e 75 2c 20 6e | 69 6c 29 3b 0d 09 09 09 |lMenu, n|il);....|
|00002ac0| 09 09 09 54 45 6e 74 65 | 72 49 43 4f 4e 3a 0d 09 |...TEnte|rICON:..|
|00002ad0| 09 09 09 09 09 09 49 66 | 20 28 4e 6f 54 65 78 74 |......If| (NoText|
|00002ae0| 20 3c 20 4e 6f 53 74 72 | 69 6e 67 73 29 20 74 68 | < NoStr|ings) th|
|00002af0| 65 6e 20 62 65 67 69 6e | 0d 09 09 09 09 09 09 09 |en begin|........|
|00002b00| 09 45 6e 74 65 72 54 65 | 78 74 20 28 64 65 76 69 |.EnterTe|xt (devi|
|00002b10| 63 65 29 3b 0d 09 09 09 | 09 09 09 09 09 44 69 74 |ce);....|.....Dit|
|00002b20| 6c 54 65 78 74 28 64 65 | 76 69 63 65 2e 64 63 74 |lText(de|vice.dct|
|00002b30| 6c 53 74 6f 72 61 67 65 | 5e 5e 29 3b 0d 09 09 09 |lStorage|^^);....|
|00002b40| 09 09 09 09 65 6e 64 3b | 0d 09 09 09 09 09 09 52 |....end;|.......R|
|00002b50| 61 64 69 6f 42 75 74 31 | 3a 0d 09 09 09 09 09 09 |adioBut1|:.......|
|00002b60| 09 43 74 6c 52 61 64 69 | 6f 42 75 74 74 6f 6e 73 |.CtlRadi|oButtons|
|00002b70| 20 28 44 65 76 69 63 65 | 2c 20 31 29 3b 0d 09 09 | (Device|, 1);...|
|00002b80| 09 09 09 09 52 61 64 69 | 6f 42 75 74 32 3a 0d 09 |....Radi|oBut2:..|
|00002b90| 09 09 09 09 09 09 43 74 | 6c 52 61 64 69 6f 42 75 |......Ct|lRadioBu|
|00002ba0| 74 74 6f 6e 73 20 28 44 | 65 76 69 63 65 2c 20 32 |ttons (D|evice, 2|
|00002bb0| 29 3b 0d 09 09 09 09 09 | 09 52 61 64 69 6f 42 75 |);......|.RadioBu|
|00002bc0| 74 33 3a 0d 09 09 09 09 | 09 09 09 43 74 6c 52 61 |t3:.....|...CtlRa|
|00002bd0| 64 69 6f 42 75 74 74 6f | 6e 73 20 28 44 65 76 69 |dioButto|ns (Devi|
|00002be0| 63 65 2c 20 33 29 3b 0d | 09 09 09 09 09 09 6f 74 |ce, 3);.|......ot|
|00002bf0| 68 65 72 77 69 73 65 3b | 09 7b 20 69 67 6e 6f 72 |herwise;|.{ ignor|
|00002c00| 65 20 61 6c 6c 20 6f 74 | 68 65 72 20 6d 6f 75 73 |e all ot|her mous|
|00002c10| 65 64 6f 77 6e 73 20 7d | 0d 09 09 09 09 09 65 6e |edowns }|......en|
|00002c20| 64 3b 20 20 20 7b 20 69 | 66 20 44 69 61 6c 6f 67 |d; { i|f Dialog|
|00002c30| 53 65 6c 65 63 74 2f 63 | 61 73 65 20 6f 66 20 69 |Select/c|ase of i|
|00002c40| 74 65 6d 20 68 69 74 20 | 7d 0d 09 09 09 09 65 6e |tem hit |}.....en|
|00002c50| 64 3b 20 20 20 7b 20 4d | 6f 75 73 65 44 6f 77 6e |d; { M|ouseDown|
|00002c60| 20 63 61 73 65 20 7d 0d | 09 09 09 4b 65 79 44 6f | case }.|...KeyDo|
|00002c70| 77 6e 3a 0d 09 09 09 09 | 64 6f 4b 65 79 45 76 65 |wn:.....|doKeyEve|
|00002c80| 6e 74 20 28 64 65 76 69 | 63 65 2c 20 45 76 65 6e |nt (devi|ce, Even|
|00002c90| 74 50 74 72 29 3b 0d 09 | 09 09 55 70 64 61 74 65 |tPtr);..|..Update|
|00002ca0| 45 76 74 3a 0d 09 09 09 | 09 55 70 64 61 74 65 44 |Evt:....|.UpdateD|
|00002cb0| 41 28 64 65 76 69 63 65 | 29 3b 0d 09 09 09 41 63 |A(device|);....Ac|
|00002cc0| 74 69 76 61 74 65 45 76 | 74 3a 0d 09 09 09 09 69 |tivateEv|t:.....i|
|00002cd0| 66 20 6f 64 64 28 45 76 | 65 6e 74 50 74 72 5e 2e |f odd(Ev|entPtr^.|
|00002ce0| 6d 6f 64 69 66 69 65 72 | 73 29 0d 09 09 09 09 09 |modifier|s)......|
|00002cf0| 74 68 65 6e 20 44 41 61 | 63 74 69 76 61 74 65 28 |then DAa|ctivate(|
|00002d00| 64 65 76 69 63 65 29 0d | 09 09 09 09 09 65 6c 73 |device).|.....els|
|00002d10| 65 20 44 41 64 65 61 63 | 74 69 76 61 74 65 28 64 |e DAdeac|tivate(d|
|00002d20| 65 76 69 63 65 29 3b 0d | 09 09 09 6f 74 68 65 72 |evice);.|...other|
|00002d30| 77 69 73 65 3b 09 7b 20 | 69 67 6e 6f 72 65 20 61 |wise;.{ |ignore a|
|00002d40| 6c 6c 20 6f 74 68 65 72 | 20 65 76 65 6e 74 73 20 |ll other| events |
|00002d50| 7d 0d 09 09 65 6e 64 3b | 20 7b 20 63 61 73 65 20 |}...end;| { case |
|00002d60| 6f 66 20 77 68 61 74 20 | 7d 0d 09 65 6e 64 3b 20 |of what |}..end; |
|00002d70| 20 20 7b 20 77 69 74 68 | 20 45 76 65 6e 74 52 65 | { with| EventRe|
|00002d80| 63 6f 72 64 20 7d 0d 65 | 6e 64 3b 20 7b 20 45 76 |cord }.e|nd; { Ev|
|00002d90| 65 6e 74 20 50 72 6f 63 | 65 64 75 72 65 20 7d 0d |ent Proc|edure }.|
|00002da0| 0d 50 52 4f 43 45 44 55 | 52 45 20 4f 70 65 6e 28 |.PROCEDU|RE Open(|
|00002db0| 56 41 52 20 44 65 76 69 | 63 65 20 3a 20 44 65 76 |VAR Devi|ce : Dev|
|00002dc0| 69 63 65 43 6f 6e 74 72 | 6f 6c 52 65 63 3b 20 56 |iceContr|olRec; V|
|00002dd0| 41 52 20 42 6c 6f 63 6b | 20 3a 20 50 61 72 61 6d |AR Block| : Param|
|00002de0| 42 6c 6f 63 6b 52 65 63 | 29 3b 0d 56 41 52 0d 09 |BlockRec|);.VAR..|
|00002df0| 54 6d 70 50 74 72 3a 09 | 09 50 74 72 3b 0d 09 57 |TmpPtr:.|.Ptr;..W|
|00002e00| 50 65 65 6b 3a 09 09 57 | 69 6e 64 6f 77 50 65 65 |Peek:..W|indowPee|
|00002e10| 6b 3b 0d 09 52 65 73 6f | 75 72 63 65 49 44 3a 09 |k;..Reso|urceID:.|
|00002e20| 49 6e 74 65 67 65 72 3b | 09 7b 49 44 20 74 6f 20 |Integer;|.{ID to |
|00002e30| 74 68 65 20 64 69 61 6c | 6f 67 20 69 74 65 6d 20 |the dial|og item |
|00002e40| 6c 69 73 74 20 26 20 6d | 61 69 6e 20 72 65 66 65 |list & m|ain refe|
|00002e50| 72 65 6e 63 65 20 49 44 | 20 66 6f 72 20 72 65 73 |rence ID| for res|
|00002e60| 6f 75 72 63 65 73 7d 0d | 42 45 47 49 4e 09 7b 20 |ources}.|BEGIN.{ |
|00002e70| 20 4f 70 65 6e 20 50 72 | 6f 63 65 64 75 72 65 20 | Open Pr|ocedure |
|00002e80| 20 7d 0d 09 52 65 73 6f | 75 72 63 65 49 44 20 3a | }..Reso|urceID :|
|00002e90| 3d 20 24 42 46 45 30 20 | 2b 20 33 32 20 2a 20 28 |= $BFE0 |+ 32 * (|
|00002ea0| 2d 44 65 76 69 63 65 2e | 44 43 74 6c 52 65 66 4e |-Device.|DCtlRefN|
|00002eb0| 75 6d 29 3b 09 09 09 7b | 20 43 6f 6d 70 75 74 65 |um);...{| Compute|
|00002ec0| 20 6d 61 69 6e 20 72 65 | 73 6f 75 72 63 65 20 49 | main re|source I|
|00002ed0| 44 20 7d 0d 09 44 65 76 | 69 63 65 2e 64 43 74 6c |D }..Dev|ice.dCtl|
|00002ee0| 4d 65 6e 75 20 3a 3d 20 | 52 65 73 6f 75 72 63 65 |Menu := |Resource|
|00002ef0| 49 44 3b 0d 09 69 66 20 | 44 65 76 69 63 65 2e 44 |ID;..if |Device.D|
|00002f00| 63 74 6c 57 69 6e 64 6f | 77 20 3d 20 6e 69 6c 20 |ctlWindo|w = nil |
|00002f10| 74 68 65 6e 20 62 65 67 | 69 6e 0d 09 09 44 65 76 |then beg|in...Dev|
|00002f20| 69 63 65 2e 44 63 74 6c | 53 74 6f 72 61 67 65 20 |ice.Dctl|Storage |
|00002f30| 3a 3d 20 20 44 41 47 6c | 6f 62 61 6c 73 48 28 4e |:= DAGl|obalsH(N|
|00002f40| 65 77 48 61 6e 64 6c 65 | 28 31 33 32 29 29 3b 0d |ewHandle|(132));.|
|00002f50| 09 09 54 6d 70 50 74 72 | 20 3a 3d 20 4e 65 77 50 |..TmpPtr| := NewP|
|00002f60| 74 72 28 24 31 30 30 30 | 29 3b 09 09 09 09 7b 20 |tr($1000|);....{ |
|00002f70| 43 72 65 61 74 65 20 68 | 6f 6c 65 20 69 6e 20 74 |Create h|ole in t|
|00002f80| 68 65 20 68 65 61 70 20 | 75 6e 64 65 72 20 57 69 |he heap |under Wi|
|00002f90| 6e 64 6f 77 20 72 65 63 | 6f 72 64 20 7d 0d 09 09 |ndow rec|ord }...|
|00002fa0| 44 65 76 69 63 65 2e 44 | 43 74 6c 57 69 6e 64 6f |Device.D|CtlWindo|
|00002fb0| 77 3a 3d 20 47 65 74 4e | 65 77 44 69 61 6c 6f 67 |w:= GetN|ewDialog|
|00002fc0| 20 28 52 65 73 6f 75 72 | 63 65 49 44 2c 20 4e 69 | (Resour|ceID, Ni|
|00002fd0| 6c 2c 20 70 6f 69 6e 74 | 65 72 28 2d 31 29 29 3b |l, point|er(-1));|
|00002fe0| 0d 09 09 57 50 65 65 6b | 20 3a 3d 20 70 6f 69 6e |...WPeek| := poin|
|00002ff0| 74 65 72 28 6f 72 64 28 | 44 65 76 69 63 65 2e 44 |ter(ord(|Device.D|
|00003000| 43 74 6c 57 69 6e 64 6f | 77 29 29 3b 0d 09 09 57 |CtlWindo|w));...W|
|00003010| 50 65 65 6b 5e 2e 57 69 | 6e 64 6f 77 4b 69 6e 64 |Peek^.Wi|ndowKind|
|00003020| 20 3a 3d 20 44 65 76 69 | 63 65 2e 44 43 74 6c 52 | := Devi|ce.DCtlR|
|00003030| 65 66 4e 75 6d 3b 09 7b | 73 65 74 20 74 68 65 20 |efNum;.{|set the |
|00003040| 57 69 6e 64 6f 77 4b 69 | 6e 64 20 66 69 65 6c 64 |WindowKi|nd field|
|00003050| 20 74 6f 20 74 68 65 20 | 44 41 20 52 65 66 4e 75 | to the |DA RefNu|
|00003060| 6d 20 7d 0d 09 09 53 65 | 74 50 6f 72 74 28 44 65 |m }...Se|tPort(De|
|00003070| 76 69 63 65 2e 44 43 74 | 6c 57 69 6e 64 6f 77 29 |vice.DCt|lWindow)|
|00003080| 3b 0d 09 09 44 69 73 70 | 6f 73 50 74 72 28 54 6d |;...Disp|osPtr(Tm|
|00003090| 70 50 74 72 29 3b 0d 0d | 09 09 48 4c 6f 63 6b 20 |pPtr);..|..HLock |
|000030a0| 28 48 61 6e 64 6c 65 20 | 28 44 65 76 69 63 65 2e |(Handle |(Device.|
|000030b0| 64 43 74 6c 73 74 6f 72 | 61 67 65 29 29 3b 0d 09 |dCtlstor|age));..|
|000030c0| 09 57 69 74 68 20 44 65 | 76 69 63 65 2e 64 43 74 |.With De|vice.dCt|
|000030d0| 6c 73 74 6f 72 61 67 65 | 5e 5e 20 64 6f 20 62 65 |lstorage|^^ do be|
|000030e0| 67 69 6e 0d 09 09 09 49 | 6e 69 74 44 6c 6f 67 53 |gin....I|nitDlogS|
|000030f0| 74 61 74 75 73 28 64 65 | 76 69 63 65 29 3b 0d 09 |tatus(de|vice);..|
|00003100| 09 09 46 69 6e 69 73 68 | 65 64 20 3a 3d 20 46 61 |..Finish|ed := Fa|
|00003110| 6c 73 65 3b 20 09 09 09 | 09 7b 20 73 65 74 20 70 |lse; ...|.{ set p|
|00003120| 72 6f 67 72 61 6d 20 74 | 65 72 6d 69 6e 61 74 6f |rogram t|erminato|
|00003130| 72 20 74 6f 20 66 61 6c | 73 65 20 7d 0d 09 09 09 |r to fal|se }....|
|00003140| 6d 65 6e 75 48 61 6e 64 | 20 3a 3d 20 47 65 74 4d |menuHand| := GetM|
|00003150| 65 6e 75 20 28 52 65 73 | 6f 75 72 63 65 49 44 29 |enu (Res|ourceID)|
|00003160| 3b 0d 09 09 65 6e 64 3b | 0d 09 09 48 55 6e 6c 6f |;...end;|...HUnlo|
|00003170| 63 6b 28 48 61 6e 64 6c | 65 28 44 65 76 69 63 65 |ck(Handl|e(Device|
|00003180| 2e 44 63 74 6c 73 74 6f | 72 61 67 65 29 29 3b 0d |.Dctlsto|rage));.|
|00003190| 09 65 6e 64 3b 0d 45 4e | 44 3b 20 20 7b 20 6f 66 |.end;.EN|D; { of|
|000031a0| 20 4f 70 65 6e 20 7d 0d | 0d 50 52 4f 43 45 44 55 | Open }.|.PROCEDU|
|000031b0| 52 45 20 43 74 6c 20 28 | 56 41 52 20 44 65 76 69 |RE Ctl (|VAR Devi|
|000031c0| 63 65 20 3a 20 44 65 76 | 69 63 65 43 6f 6e 74 72 |ce : Dev|iceContr|
|000031d0| 6f 6c 52 65 63 3b 20 56 | 41 52 20 42 6c 6f 63 6b |olRec; V|AR Block|
|000031e0| 20 3a 20 50 61 72 61 6d | 42 6c 6f 63 6b 52 65 63 | : Param|BlockRec|
|000031f0| 29 3b 0d 43 4f 4e 53 54 | 0d 09 61 63 63 45 76 65 |);.CONST|..accEve|
|00003200| 6e 74 09 09 3d 20 36 34 | 3b 09 61 63 63 55 6e 64 |nt..= 64|;.accUnd|
|00003210| 6f 09 09 3d 20 36 38 3b | 09 61 63 63 43 6c 65 61 |o..= 68;|.accClea|
|00003220| 72 09 09 3d 20 37 33 3b | 0d 09 61 63 63 52 75 6e |r..= 73;|..accRun|
|00003230| 09 09 3d 20 36 35 3b 09 | 61 63 63 43 75 74 09 09 |..= 65;.|accCut..|
|00003240| 3d 20 37 30 3b 09 43 6d | 64 4d 65 6e 75 4e 6f 09 |= 70;.Cm|dMenuNo.|
|00003250| 3d 20 31 3b 0d 09 61 63 | 63 43 75 72 73 6f 72 09 |= 1;..ac|cCursor.|
|00003260| 3d 20 36 36 3b 09 61 63 | 63 43 6f 70 79 09 09 3d |= 66;.ac|cCopy..=|
|00003270| 20 37 31 3b 09 41 62 6f | 75 74 4d 65 6e 75 4e 6f | 71;.Abo|utMenuNo|
|00003280| 09 3d 20 33 3b 0d 09 61 | 63 63 4d 65 6e 75 09 09 |.= 3;..a|ccMenu..|
|00003290| 3d 20 36 37 3b 09 61 63 | 63 50 61 73 74 65 09 09 |= 67;.ac|cPaste..|
|000032a0| 3d 20 37 32 3b 09 51 75 | 69 74 4d 65 6e 75 4e 6f |= 72;.Qu|itMenuNo|
|000032b0| 09 3d 20 34 3b 0d 56 41 | 52 0d 09 44 6f 6e 65 09 |.= 4;.VA|R..Done.|
|000032c0| 3a 20 62 6f 6f 6c 65 61 | 6e 3b 09 20 7b 20 6c 6f |: boolea|n;. { lo|
|000032d0| 63 61 6c 20 70 67 6d 20 | 74 65 72 6d 69 6e 61 74 |cal pgm |terminat|
|000032e0| 6f 72 20 2d 20 66 6f 72 | 20 63 61 6c 6c 69 6e 67 |or - for| calling|
|000032f0| 20 43 6c 6f 73 65 44 65 | 73 6b 41 63 63 20 61 66 | CloseDe|skAcc af|
|00003300| 74 65 72 20 67 6c 6f 62 | 61 6c 73 20 75 6e 6c 6f |ter glob|als unlo|
|00003310| 63 6b 65 64 20 7d 0d 09 | 44 50 65 65 6b 09 3a 20 |cked }..|DPeek.: |
|00003320| 44 69 61 6c 6f 67 50 65 | 65 6b 3b 0d 42 45 47 49 |DialogPe|ek;.BEGI|
|00003330| 4e 20 7b 20 4d 61 69 6e | 20 62 6f 64 79 20 6f 66 |N { Main| body of|
|00003340| 20 43 54 4c 20 50 72 6f | 63 65 64 75 72 65 20 7d | CTL Pro|cedure }|
|00003350| 0d 09 42 69 74 43 6c 72 | 28 40 44 65 76 69 63 65 |..BitClr|(@Device|
|00003360| 2e 64 43 74 6c 46 6c 61 | 67 73 2c 20 35 29 3b 09 |.dCtlFla|gs, 5);.|
|00003370| 09 09 7b 20 70 72 65 76 | 65 6e 74 20 43 54 4c 20 |..{ prev|ent CTL |
|00003380| 63 61 6c 6c 73 20 75 6e | 74 69 6c 20 64 6f 6e 65 |calls un|til done|
|00003390| 2c 20 73 69 6e 63 65 20 | 77 65 20 75 73 65 20 6d |, since |we use m|
|000033a0| 6f 64 61 6c 64 69 61 6c | 6f 67 73 20 7d 0d 09 53 |odaldial|ogs }..S|
|000033b0| 65 74 50 6f 72 74 28 44 | 65 76 69 63 65 2e 44 43 |etPort(D|evice.DC|
|000033c0| 74 6c 57 69 6e 64 6f 77 | 29 3b 09 09 09 7b 20 53 |tlWindow|);...{ S|
|000033d0| 65 74 20 74 68 65 20 63 | 75 72 72 65 6e 74 20 67 |et the c|urrent g|
|000033e0| 72 61 66 70 6f 72 74 20 | 7d 0d 09 48 4c 6f 63 6b |rafport |}..HLock|
|000033f0| 28 48 61 6e 64 6c 65 28 | 44 65 76 69 63 65 2e 44 |(Handle(|Device.D|
|00003400| 43 74 6c 53 74 6f 72 61 | 67 65 29 29 3b 09 09 7b |CtlStora|ge));..{|
|00003410| 20 6c 6f 63 6b 20 44 41 | 47 6c 6f 62 61 6c 73 20 | lock DA|Globals |
|00003420| 64 6f 77 6e 20 7d 0d 09 | 44 6f 6e 65 20 3a 3d 20 |down }..|Done := |
|00003430| 46 61 6c 73 65 3b 09 09 | 09 09 09 09 7b 20 73 65 |False;..|....{ se|
|00003440| 74 20 6c 6f 63 61 6c 20 | 62 6f 6f 6c 65 61 6e 20 |t local |boolean |
|00003450| 70 72 6f 67 72 61 6d 20 | 74 65 72 6d 69 6e 61 74 |program |terminat|
|00003460| 6f 72 20 7d 0d 09 77 69 | 74 68 20 64 65 76 69 63 |or }..wi|th devic|
|00003470| 65 2e 64 63 74 6c 53 74 | 6f 72 61 67 65 5e 5e 20 |e.dctlSt|orage^^ |
|00003480| 64 6f 0d 09 09 77 69 74 | 68 20 62 6c 6f 63 6b 20 |do...wit|h block |
|00003490| 64 6f 20 62 65 67 69 6e | 0d 09 09 09 63 61 73 65 |do begin|....case|
|000034a0| 20 63 73 43 6f 64 65 20 | 6f 66 0d 09 09 09 09 61 | csCode |of.....a|
|000034b0| 63 63 45 76 65 6e 74 3a | 0d 09 09 09 09 09 45 76 |ccEvent:|......Ev|
|000034c0| 65 6e 74 28 44 65 76 69 | 63 65 2c 20 42 6c 6f 63 |ent(Devi|ce, Bloc|
|000034d0| 6b 29 3b 0d 09 09 09 09 | 61 63 63 52 75 6e 3a 0d |k);.....|accRun:.|
|000034e0| 09 09 09 20 20 20 20 09 | 09 62 65 67 69 6e 0d 09 |... .|.begin..|
|000034f0| 09 09 09 09 09 44 50 65 | 65 6b 20 3a 3d 20 44 69 |.....DPe|ek := Di|
|00003500| 61 6c 6f 67 50 65 65 6b | 28 44 65 76 69 63 65 2e |alogPeek|(Device.|
|00003510| 44 43 74 6c 57 69 6e 64 | 6f 77 29 3b 0d 09 09 09 |DCtlWind|ow);....|
|00003520| 09 09 09 54 45 49 64 6c | 65 20 28 44 50 65 65 6b |...TEIdl|e (DPeek|
|00003530| 5e 2e 74 65 78 74 48 29 | 3b 09 09 7b 20 62 6c 69 |^.textH)|;..{ bli|
|00003540| 6e 6b 20 63 61 72 65 74 | 20 69 6e 20 74 65 78 74 |nk caret| in text|
|00003550| 20 62 6f 78 20 7d 0d 20 | 09 09 09 20 20 20 20 09 | box }. |... .|
|00003560| 09 65 6e 64 3b 0d 09 09 | 09 09 61 63 63 43 75 72 |.end;...|..accCur|
|00003570| 73 6f 72 3a 20 3b 0d 09 | 09 09 09 61 63 63 4d 65 |sor: ;..|...accMe|
|00003580| 6e 75 3a 0d 09 09 09 20 | 20 20 20 09 09 62 65 67 |nu:.... | ..beg|
|00003590| 69 6e 0d 09 09 09 09 09 | 09 63 61 73 65 20 63 73 |in......|.case cs|
|000035a0| 50 61 72 61 6d 5b 31 5d | 20 6f 66 0d 09 09 09 09 |Param[1]| of.....|
|000035b0| 09 09 09 43 6d 64 4d 65 | 6e 75 4e 6f 3a 0d 09 09 |...CmdMe|nuNo:...|
|000035c0| 09 09 09 09 09 09 44 6f | 41 62 6f 75 74 28 64 65 |......Do|About(de|
|000035d0| 76 69 63 65 2e 64 63 74 | 6c 4d 65 6e 75 20 2b 20 |vice.dct|lMenu + |
|000035e0| 33 29 3b 0d 09 09 09 09 | 09 09 09 41 62 6f 75 74 |3);.....|...About|
|000035f0| 4d 65 6e 75 4e 6f 3a 0d | 09 09 09 09 09 09 09 09 |MenuNo:.|........|
|00003600| 44 6f 41 62 6f 75 74 28 | 64 65 76 69 63 65 2e 64 |DoAbout(|device.d|
|00003610| 63 74 6c 4d 65 6e 75 20 | 2b 20 31 29 3b 0d 09 09 |ctlMenu |+ 1);...|
|00003620| 09 09 09 09 09 51 75 69 | 74 4d 65 6e 75 4e 6f 3a |.....Qui|tMenuNo:|
|00003630| 0d 09 09 09 09 09 20 20 | 20 20 09 09 09 46 69 6e |...... | ...Fin|
|00003640| 69 73 68 65 64 20 3a 3d | 20 54 72 75 65 3b 0d 09 |ished :=| True;..|
|00003650| 09 09 09 09 09 65 6e 64 | 3b 20 20 7b 20 63 61 73 |.....end|; { cas|
|00003660| 65 20 6f 66 20 6d 65 6e | 75 20 7d 0d 09 09 09 09 |e of men|u }.....|
|00003670| 09 09 48 69 6c 69 74 65 | 4d 65 6e 75 28 30 29 3b |..Hilite|Menu(0);|
|00003680| 0d 09 09 09 20 20 20 20 | 09 09 65 6e 64 3b 09 7b |.... |..end;.{|
|00003690| 20 6d 65 6e 75 20 63 61 | 73 65 7d 0d 09 09 09 09 | menu ca|se}.....|
|000036a0| 61 63 63 55 6e 64 6f 3a | 20 20 20 3b 0d 09 09 09 |accUndo:| ;....|
|000036b0| 09 61 63 63 43 75 74 3a | 20 20 20 20 3b 0d 09 09 |.accCut:| ;...|
|000036c0| 09 09 61 63 63 43 6f 70 | 79 3a 20 20 20 3b 0d 09 |..accCop|y: ;..|
|000036d0| 09 09 09 61 63 63 50 61 | 73 74 65 3a 20 20 3b 0d |...accPa|ste: ;.|
|000036e0| 09 09 09 09 61 63 63 43 | 6c 65 61 72 3a 20 20 3b |....accC|lear: ;|
|000036f0| 0d 09 09 09 65 6e 64 3b | 09 7b 20 63 61 73 65 20 |....end;|.{ case |
|00003700| 6f 66 20 63 73 43 6f 64 | 65 20 7d 0d 09 09 09 44 |of csCod|e }....D|
|00003710| 6f 6e 65 20 3a 3d 20 46 | 69 6e 69 73 68 65 64 3b |one := F|inished;|
|00003720| 0d 09 09 65 6e 64 3b 09 | 7b 20 6f 66 20 42 6c 6f |...end;.|{ of Blo|
|00003730| 63 6b 2f 64 65 76 69 63 | 65 2e 64 63 74 6c 53 74 |ck/devic|e.dctlSt|
|00003740| 6f 72 61 67 65 5e 5e 20 | 7d 0d 09 48 55 6e 4c 6f |orage^^ |}..HUnLo|
|00003750| 63 6b 28 48 61 6e 64 6c | 65 28 44 65 76 69 63 65 |ck(Handl|e(Device|
|00003760| 2e 44 43 74 6c 53 74 6f | 72 61 67 65 29 29 3b 0d |.DCtlSto|rage));.|
|00003770| 09 42 69 74 53 65 74 28 | 40 44 65 76 69 63 65 2e |.BitSet(|@Device.|
|00003780| 64 43 74 6c 46 6c 61 67 | 73 2c 20 35 29 3b 09 09 |dCtlFlag|s, 5);..|
|00003790| 09 09 7b 41 6c 6c 6f 77 | 20 5f 43 6f 6e 74 72 6f |..{Allow| _Contro|
|000037a0| 6c 20 63 61 6c 6c 73 20 | 61 67 61 69 6e 2e 7d 0d |l calls |again.}.|
|000037b0| 09 69 66 20 44 6f 6e 65 | 20 74 68 65 6e 20 43 6c |.if Done| then Cl|
|000037c0| 6f 73 65 44 65 73 6b 41 | 63 63 28 44 65 76 69 63 |oseDeskA|cc(Devic|
|000037d0| 65 2e 44 43 74 6c 52 65 | 66 4e 75 6d 29 3b 0d 45 |e.DCtlRe|fNum);.E|
|000037e0| 4e 44 3b 20 20 7b 20 6f | 66 20 43 74 6c 20 7d 0d |ND; { o|f Ctl }.|
|000037f0| 0d 50 52 4f 43 45 44 55 | 52 45 20 43 6c 6f 73 65 |.PROCEDU|RE Close|
|00003800| 28 56 41 52 20 44 65 76 | 69 63 65 3a 20 44 65 76 |(VAR Dev|ice: Dev|
|00003810| 69 63 65 43 6f 6e 74 72 | 6f 6c 52 65 63 3b 20 20 |iceContr|olRec; |
|00003820| 56 41 52 20 42 6c 6f 63 | 6b 20 3a 20 50 61 72 61 |VAR Bloc|k : Para|
|00003830| 6d 42 6c 6f 63 6b 52 65 | 63 29 3b 0d 42 45 47 49 |mBlockRe|c);.BEGI|
|00003840| 4e 0d 09 44 41 64 65 61 | 63 74 69 76 61 74 65 28 |N..DAdea|ctivate(|
|00003850| 64 65 76 69 63 65 29 3b | 0d 09 77 69 74 68 20 44 |device);|..with D|
|00003860| 65 76 69 63 65 20 64 6f | 0d 09 09 62 65 67 69 6e |evice do|...begin|
|00003870| 0d 09 09 09 64 69 73 70 | 6f 73 44 69 61 6c 6f 67 |....disp|osDialog|
|00003880| 28 44 69 61 6c 6f 67 50 | 74 72 28 64 43 74 6c 57 |(DialogP|tr(dCtlW|
|00003890| 69 6e 64 6f 77 29 29 3b | 09 7b 20 64 69 73 70 6f |indow));|.{ dispo|
|000038a0| 73 65 20 6f 66 20 77 69 | 6e 64 6f 77 20 7d 0d 09 |se of wi|ndow }..|
|000038b0| 09 09 52 65 6c 65 61 73 | 65 52 65 73 6f 75 72 63 |..Releas|eResourc|
|000038c0| 65 20 28 48 61 6e 64 6c | 65 20 28 44 43 74 6c 53 |e (Handl|e (DCtlS|
|000038d0| 74 6f 72 61 67 65 5e 5e | 2e 6d 65 6e 75 48 61 6e |torage^^|.menuHan|
|000038e0| 64 29 29 3b 0d 09 09 09 | 48 50 75 72 67 65 28 48 |d));....|HPurge(H|
|000038f0| 61 6e 64 6c 65 28 64 43 | 74 6c 44 72 69 76 65 72 |andle(dC|tlDriver|
|00003900| 29 29 3b 0d 09 09 09 64 | 63 74 6c 57 69 6e 64 6f |));....d|ctlWindo|
|00003910| 77 20 3a 3d 20 6e 69 6c | 3b 0d 09 09 09 64 69 73 |w := nil|;....dis|
|00003920| 70 6f 73 48 61 6e 64 6c | 65 28 48 61 6e 64 6c 65 |posHandl|e(Handle|
|00003930| 28 64 43 74 6c 53 74 6f | 72 61 67 65 29 29 3b 09 |(dCtlSto|rage));.|
|00003940| 09 7b 20 52 65 6c 65 61 | 73 65 20 70 72 69 76 61 |.{ Relea|se priva|
|00003950| 74 65 20 73 74 6f 72 61 | 67 65 20 61 72 65 61 20 |te stora|ge area |
|00003960| 7d 0d 09 09 09 64 63 74 | 6c 53 74 6f 72 61 67 65 |}....dct|lStorage|
|00003970| 20 3a 3d 20 6e 69 6c 3b | 0d 09 09 65 6e 64 3b 0d | := nil;|...end;.|
|00003980| 45 4e 44 3b 20 20 7b 20 | 6f 66 20 43 6c 6f 73 65 |END; { |of Close|
|00003990| 20 7d 0d 0d 42 45 47 49 | 4e 09 20 7b 20 4e 6f 20 | }..BEGI|N. { No |
|000039a0| 6d 61 69 6e 20 70 72 6f | 67 72 61 6d 20 7d 0d 45 |main pro|gram }.E|
|000039b0| 4e 44 2e 0d 00 00 00 00 | 00 00 00 00 00 00 00 00 |ND......|........|
|000039c0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000039d0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000039e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000039f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003a00| 00 00 01 00 00 00 01 3c | 00 00 00 3c 00 00 00 5a |.......<|...<...Z|
|00003a10| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 02 00 |........|........|
|00003a20| 00 88 02 80 00 00 00 00 | 00 00 00 00 00 00 01 00 |........|........|
|00003a30| 13 44 69 61 6c 6f 67 4d | 61 6e 61 67 65 72 44 41 |.DialogM|anagerDA|
|00003a40| 2e 50 61 73 02 00 00 00 | 54 45 58 54 51 45 44 31 |.Pas....|TEXTQED1|
|00003a50| 00 00 54 45 58 54 51 45 | 44 31 01 00 00 00 00 80 |..TEXTQE|D1......|
|00003a60| 00 00 00 84 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003a70| 00 00 9a 60 20 77 00 00 | 39 34 00 00 01 96 00 00 |...` w..|94......|
|00003a80| 00 00 00 00 00 00 00 00 | 00 00 38 38 3f c0 00 00 |........|..88?...|
|00003a90| 00 00 07 00 01 c0 00 00 | 00 03 80 f0 00 00 00 00 |........|........|
|00003aa0| 00 0f 00 0e 00 00 01 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003ab0| 04 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003ac0| 00 00 00 f0 06 c0 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003ad0| 00 00 00 00 00 10 00 00 | 00 c8 00 0c 00 00 00 00 |........|........|
|00003ae0| 00 00 00 00 00 00 00 0f | 00 00 00 00 00 00 00 00 |........|........|
|00003af0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 03 01 |........|........|
|00003b00| 00 00 00 2a 00 09 06 47 | 65 6e 65 76 61 00 00 00 |...*...G|eneva...|
|00003b10| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003b20| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003b30| 00 04 00 06 00 04 00 00 | 00 02 00 00 00 00 01 00 |........|........|
|00003b40| 00 00 01 3c 00 00 00 3c | 00 00 00 5a 00 00 cc 24 |...<...<|...Z...$|
|00003b50| 01 7a 00 00 00 1c 00 5a | 00 02 45 46 4e 54 00 00 |.z.....Z|..EFNT..|
|00003b60| 00 1a 45 54 41 42 00 00 | 00 26 45 51 45 44 00 00 |..ETAB..|.&EQED..|
|00003b70| 00 32 03 eb ff ff 00 00 | 00 00 00 00 00 00 03 ec |.2......|........|
|00003b80| ff ff 00 00 00 2e 00 00 | 00 00 03 eb ff ff 00 00 |........|........|
|00003b90| 00 36 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |.6......|........|
|00003ba0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003bb0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003bc0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003bd0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003be0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003bf0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
+--------+-------------------------+-------------------------+--------+--------+